home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 10 / AACD 10.iso / AACD / Games / MAME / src / drivers / exidy440.c < prev    next >
Text File  |  2000-04-23  |  69KB  |  1,771 lines

  1. /***************************************************************************
  2.  
  3.     Exidy 440 system
  4.  
  5.     driver by Aaron Giles
  6.  
  7.  
  8.     Currently implemented:
  9.         * Crossbow
  10.         * Cheyenne
  11.         * Combat
  12.         * Crackshot
  13.         * Chiller
  14.         * Top Secret
  15.         * Clay Pigeon
  16.         * Hit 'n Miss
  17.         * Who Dunit
  18.         * Showdown
  19.  
  20.  
  21. ****************************************************************************
  22.  
  23.     Memory map
  24.  
  25. ****************************************************************************
  26.  
  27.     ========================================================================
  28.     CPU #1
  29.     ========================================================================
  30.     0000-1FFF   R/W   xxxxxxxx    Image RAM (64 images x 128 bytes, each image is 16x16x4bpp)
  31.                 R/W   xxxx----       (left pixel)
  32.                 R/W   ----xxxx       (right pixel)
  33.     2000-209F   R/W   xxxxxxxx    Sprite RAM (40 entries x 4 bytes)
  34.                 R/W   xxxxxxxx       (0: Y position, inverted)
  35.                 R/W   -------x       (1: X position, upper bit, inverted)
  36.                 R/W   xxxxxxxx       (2: X position, lower 8 bits, inverted)
  37.                 R/W   --xxxxxx       (3: image number, inverted)
  38.     20A0-29FF   R/W   xxxxxxxx    Stack RAM
  39.     2A00-2AFF   R/W   xxxxxxxx    Scanline I/O region
  40.                 R/W   xxxx----       (left pixel)
  41.                 R/W   ----xxxx       (right pixel)
  42.     2B00        R     xxxxxxxx    Current vertical beam position
  43.     2B01        R     xxxxxxxx    Latched horizontal collision/beam detect location
  44.     2B01        W     --------    Clear VBLANK FIRQ
  45.     2B02        R/W   xxxxxxxx    Scanline I/O selector
  46.     2B03        R     xxxxxxxx    Input port
  47.                 R     x-------       (VBLANK FIRQ latched, active low)
  48.                 R     -x------       (collision/beam detect FIRQ latched, active low)
  49.                 R     --xxxx--       (4 position DIP switch, active low)
  50.                     R     ------x-       (trigger, active low)
  51.                     R     -------x       (mirror of VBLANK FIRQ latch, Whodunit only)
  52.     2B03        W     xxxxxxxx    Control port
  53.                 W     xxxx----       (ROM bank select, 0-15)
  54.                 W     ----x---       (collision/beam detect FIRQ enable)
  55.                 W     -----x--       (select FIRQ source: 0=collision, 1=beam detect)
  56.                 W     ------x-       (select palette bank for I/O)
  57.                 W     -------x       (select palette bank for display)
  58.     2C00-2DFF   R/W   xxxxxxxx    Palette RAM (2 banks x 512 bytes)
  59.                 R/W   x-------       (0: collision trigger bit)
  60.                 R/W   -xxxxx--       (0: red component)
  61.                 R/W   ------xx       (0: green component, upper 2 bits)
  62.                 R/W   xxx-----       (1: green component, lower 3 bits)
  63.                 R/W   ---xxxxx       (1: blue component)
  64.     2E00-2E1F   R/W   xxxxxxxx    Sound command
  65.     2E20-2E3F   R     ----xxxx    Coin counter, clearing IRQ
  66.                 R     ----x---       (acknowledgement of sound command read, active high)
  67.                 R     -----x--       (unknown use, active low - gives "coin mech jammed" message)
  68.                 R     ------x-       (coin 2, active low)
  69.                 R     -------x       (coin 1, active low)
  70.     2E40-2E5F   W     -------x    Clear coin counter
  71.     2E60-2E7F   R     xxxxxxxx    8 position DIP switch, active low
  72.     2E80-2E9F   R     --xxxxxx    Player control bits
  73.                 R     -------x       (start button, active low)
  74.     2EA0-2EBF   R     ----xxxx    Coin counter, non-clearing
  75.                 R     ----x---       (acknowledgement of sound command read, active high)
  76.                 R     -----x--       (unknown use, active low - gives "coin mech jammed" message)
  77.                 R     ------x-       (coin 2, active low)
  78.                 R     -------x       (coin 1, active low)
  79.     2EC0-2EDF   R     xxxxxxxx    Copy protection check (Clay Pigeon)
  80.     2EC0-2EDF    R/W    xxxxxxxx        Copy protection and I/O space (Top Secret)
  81.     3000-3FFF   R/W   xxxxxxxx    RAM
  82.     4000-7FFF   R     xxxxxxxx    Banked ROM
  83.     6000-7FFF   R/W   xxxxxxxx    EEROM (when bank 15 is selected only)
  84.     8000-FFFF   R     xxxxxxxx    Program ROM
  85.     ========================================================================
  86.     Interrupts:
  87.         NMI not connected
  88.         IRQ generated by coins, detect on audio PCB
  89.         FIRQ generated by VBLANK, collision detect, and beam detect
  90.     ========================================================================
  91.  
  92.  
  93.     ========================================================================
  94.     CPU #2
  95.     ========================================================================
  96.     0000-7FFF   R     xxxxxxxx    Banked ROM (never access because DMA switches constantly)
  97.     8000-8016   R/W   xxxxxxxx    MC6844 DMA controller I/O
  98.     8400-8407   R/W   xxxxxxxx    Volume control for each channel: left1, right1, left2, right2...
  99.     8800        R     xxxxxxxx    Sound command
  100.     9400-9403   W     xxxxxxxx    Bank select for each channel
  101.                 W     ----x---       (select bank 3, active high)
  102.                 W     -----x--       (select bank 2, active high)
  103.                 W     ------x-       (select bank 1, active high)
  104.                 W     -------x       (select bank 0, active high)
  105.     9800        W     --------    Clear sound IRQ
  106.     A000-BFFF   R/W   xxxxxxxx    RAM
  107.     E000-FFFF   R     xxxxxxxx    Program ROM
  108.     ========================================================================
  109.     Interrupts:
  110.         NMI not connected
  111.         IRQ generated by VSYNC
  112.         FIRQ generated by write to sound command register
  113.     ========================================================================
  114.  
  115. ***************************************************************************
  116.  
  117.     Differences between machines (assuming Crossbow is the base)
  118.  
  119.     Cheyenne (reports Hardware Error 5 if any of these are not true)
  120.         * a read from $2B03 must return 0 in bit 0
  121.  
  122.         conclusion: LS244 at 18J on main board needs to generate negative logic
  123.  
  124.     Combat (reports Hardware Error 1 if any of these are not true)
  125.         * a read from $2E80 must return 0's in bits 1,2,3,4,5
  126.         * a read from $2B03 must return 0 in bit 0
  127.  
  128.         conclusion: LS244 at 18J on main board needs to generate negative logic
  129.                         LS367 at 1A on audio board needs to generate negative logic
  130.  
  131.     Crackshot (reports Hardware Error W if any of these are not true)
  132.         * a read from $2E20 must return 0 in bit 2
  133.         * a read from $2E80 must return 0's in bits 1,2,3,4,5
  134.         * a read from $2B03 must return 0 in bit 0
  135.  
  136.         conclusion: LS244 at 18J on main board needs to generate negative logic
  137.                         LS367 at 1A on audio board needs to generate negative logic
  138.                         LS128 at 2A on audio board needs negative logic into pin 5
  139.  
  140.     Chiller (reports Hardware Error R if any of these are not true)
  141.         * a read from $2E20 must return 0 in bit 2
  142.         * a read from $2E80 must return 0's in bits 1,2,3,4,5
  143.         * a read from $2B03 must return 0 in bit 0
  144.  
  145.         conclusion: LS244 at 18J on main board needs to generate negative logic
  146.                         LS367 at 1A on audio board needs to generate negative logic
  147.                         LS128 at 2A on audio board needs negative logic into pin 5
  148.  
  149.     Top Secret (reports Hardware Error H if any of these are not true)
  150.         * a read from $2EC0 must return $00
  151.         * a read from $2E20 must return 0 in bit 2
  152.         * a read from $2E80 must return 0's in bits 2,3,4,5
  153.         * a read from $2B03 must return 0 in bit 0
  154.  
  155.         conclusion: LS244 at 18J on main board needs to generate negative logic
  156.                                 and must connect the inputs for bits 0 and 1
  157.                         LS367 at 1A on audio board needs to generate negative logic
  158.                         LS128 at 2A on audio board needs negative logic into pin 5
  159.                         the I/O space at $2EC0 must be hooked up to something
  160.  
  161.     Clay Pigeon (reports Hardware Error N if any of these are not true)
  162.         * a read from $2EC3 must return $76
  163.         * a read from $2E20 must return 0 in bit 2
  164.         * a read from $2E80 must return 0's in bits 1,2,3,4,5
  165.         * a read from $2B03 must return 0 in bit 0
  166.  
  167.         conclusion: LS244 at 18J on main board needs to generate negative logic
  168.                         LS367 at 1A on audio board needs to generate negative logic
  169.                         LS128 at 2A on audio board needs negative logic into pin 5
  170.                         something must be hooked up to pin 7 of the LS42 at 3A on
  171.                                 the audio board to put $76 on the data lines going
  172.                                 back to the logic board when triggered
  173.  
  174.     Hit'N Miss (reports Hardware Error H if any of these are not true)
  175.         * a read from $2E20 must return 0 in bit 2
  176.         * a read from $2E80 must return 0's in bits 2,3,4,5
  177.         * a read from $2B03 must return the same value for bit 0 as for bit 1
  178.  
  179.         conclusion: LS244 at 18J on main board needs to generate negative logic
  180.                                 and must connect the inputs for bits 0 and 1
  181.                         LS367 at 1A on audio board needs to generate negative logic
  182.                         LS128 at 2A on audio board needs negative logic into pin 5
  183.  
  184.     Who Dunit (reports Hardware Error H if any of these are not true)
  185.         * a read from $2E20 must return 0 in bit 2
  186.         * a read from $2E80 must return 0's in bits 2,3,4,5
  187.         * a read from $2B03 must return the same value for bit 0 as for bit 7
  188.  
  189.         conclusion: LS244 at 18J on main board needs to generate negative logic
  190.                                 and must connect the inputs for bits 0 and 7
  191.                         LS367 at 1A on audio board needs to generate negative logic
  192.                         LS128 at 2A on audio board needs negative logic into pin 5
  193.  
  194.     Showdown
  195.         * a read from $2E20 must return 0 in bit 2
  196.         * a read from $2E80 must return 0's in bits 1,2,3,4,5
  197.         * a read from $2B03 must return 0 in bit 0
  198.         * the PLD at 1E on the logic board must recognize the sequence $0055,$00ed
  199.             and return the following data from reads in the first 24 bytes:
  200.                 0x15,0x40,0xc1,0x8d,0x4c,0x84,0x0e,0xce,
  201.                 0x52,0xd0,0x99,0x48,0x80,0x09,0xc9,0x45,
  202.                 0xc4,0x8e,0x5a,0x92,0x18,0xd8,0x51,0xc0
  203.         * the PLD at 1E on the logic board must also recognize the sequence $0055,$1243
  204.             and return the following data from reads in the first 24 bytes:
  205.                 0x11,0x51,0xc0,0x89,0x4d,0x85,0x0c,0xcc,
  206.                 0x46,0xd2,0x98,0x59,0x91,0x08,0xc8,0x41,
  207.                 0xc5,0x8c,0x4e,0x86,0x1a,0xda,0x50,0xd1
  208.  
  209.         conclusion: something must emulate this PLD; also, not sure where the
  210.                                 bytes to compare against came from, so it's possible
  211.                                 that the real machine isn't expecting the same values
  212.                         LS244 at 18J on main board needs to generate negative logic
  213.                         LS367 at 1A on audio board needs to generate negative logic
  214.                         LS128 at 2A on audio board needs negative logic into pin 5
  215.  
  216. ***************************************************************************/
  217.  
  218. #include "driver.h"
  219. #include "vidhrdw/generic.h"
  220.  
  221.  
  222. /* globals */
  223. UINT8 exidy440_bank;
  224. UINT8 exidy440_topsecret;
  225.  
  226.  
  227. /* local variables */
  228. static UINT8 port_0_xor;
  229. static UINT8 port_2_xor;
  230. static UINT8 port_3_xor;
  231. static UINT8 mirror_vblank_bit;
  232. static UINT8 mirror_trigger_bit;
  233. static UINT8 copy_protection_read;
  234. static UINT8 coin_state;
  235. static UINT8 last_coins;
  236. static UINT8 showdown_bank_triggered;
  237.  
  238.  
  239. /* sound driver data & functions */
  240. extern UINT8 exidy440_sound_command;
  241. extern UINT8 exidy440_sound_command_ack;
  242. extern UINT8 *exidy440_m6844_data;
  243. extern UINT8 *exidy440_sound_banks;
  244. extern UINT8 *exidy440_sound_volume;
  245.  
  246. int exidy440_sh_start(const struct MachineSound *msound);
  247. void exidy440_sh_stop(void);
  248. void exidy440_sh_update(void);
  249. int exidy440_sound_interrupt(void);
  250.  
  251. READ_HANDLER( exidy440_m6844_r );
  252. WRITE_HANDLER( exidy440_m6844_w );
  253. READ_HANDLER( exidy440_sound_command_r );
  254. WRITE_HANDLER( exidy440_sound_volume_w );
  255. WRITE_HANDLER( exidy440_sound_interrupt_clear_w );
  256.  
  257.  
  258. /* video driver data & functions */
  259. extern UINT8 *spriteram;
  260. extern UINT8 *exidy440_imageram;
  261. extern UINT8 *exidy440_scanline;
  262. extern UINT8 exidy440_firq_vblank;
  263. extern UINT8 exidy440_firq_beam;
  264. extern UINT8 topsecex_yscroll;
  265.  
  266. int exidy440_vh_start(void);
  267. void exidy440_vh_stop(void);
  268. void exidy440_vh_screenrefresh(struct osd_bitmap *bitmap,int full_refresh);
  269. void topsecex_vh_screenrefresh(struct osd_bitmap *bitmap,int full_refresh);
  270. int exidy440_vblank_interrupt(void);
  271.  
  272. READ_HANDLER( exidy440_videoram_r );
  273. WRITE_HANDLER( exidy440_videoram_w );
  274. READ_HANDLER( exidy440_paletteram_r );
  275. WRITE_HANDLER( exidy440_paletteram_w );
  276. WRITE_HANDLER( exidy440_control_w );
  277. READ_HANDLER( exidy440_vertical_pos_r );
  278. READ_HANDLER( exidy440_horizontal_pos_r );
  279. WRITE_HANDLER( exidy440_interrupt_clear_w );
  280.  
  281.  
  282.  
  283. /*************************************
  284.  *
  285.  *    EEROM save/load
  286.  *
  287.  *************************************/
  288.  
  289. static void nvram_handler(void *file,int read_or_write)
  290. {
  291.     if (read_or_write)
  292.         /* the EEROM lives in the uppermost 8k of the top bank */
  293.         osd_fwrite(file, &memory_region(REGION_CPU1)[0x10000 + 15 * 0x4000 + 0x2000], 0x2000);
  294.     else
  295.     {
  296.         if (file)
  297.             osd_fread(file, &memory_region(REGION_CPU1)[0x10000 + 15 * 0x4000 + 0x2000], 0x2000);
  298.         else
  299.             memset(&memory_region(REGION_CPU1)[0x10000 + 15 * 0x4000 + 0x2000], 0, 0x2000);
  300.     }
  301. }
  302.  
  303.  
  304. /*************************************
  305.  *
  306.  *    Interrupt handling
  307.  *
  308.  *************************************/
  309.  
  310. static void handle_coins(void)
  311. {
  312.     int coins;
  313.  
  314.     /* if we got a coin, set the IRQ on the main CPU */
  315.     coins = input_port_3_r(0) & 3;
  316.     if (((coins ^ last_coins) & 0x01) && (coins & 0x01) == 0)
  317.     {
  318.         coin_state &= ~0x01;
  319.         cpu_set_irq_line(0, 0, ASSERT_LINE);
  320.     }
  321.     if (((coins ^ last_coins) & 0x02) && (coins & 0x02) == 0)
  322.     {
  323.         coin_state &= ~0x02;
  324.         cpu_set_irq_line(0, 0, ASSERT_LINE);
  325.     }
  326.     last_coins = coins;
  327. }
  328.  
  329.  
  330. static int main_interrupt(void)
  331. {
  332.     /* generate coin interrupts */
  333.     handle_coins();
  334.     return exidy440_vblank_interrupt();
  335. }
  336.  
  337.  
  338. static void init_machine(void)
  339. {
  340.     exidy440_bank = 0;
  341.     cpu_setbank(1, &memory_region(REGION_CPU1)[0x10000]);
  342.  
  343.     last_coins = input_port_3_r(0) & 3;
  344.     coin_state = 3;
  345. }
  346.  
  347.  
  348.  
  349. /*************************************
  350.  *
  351.  *    Primary input port read
  352.  *
  353.  *************************************/
  354.  
  355. static READ_HANDLER( input_r )
  356. {
  357.     int result = input_port_0_r(offset);
  358.  
  359.     /* the FIRQ cause is reflected in the upper 2 bits */
  360.     if (exidy440_firq_vblank) result ^= 0x80;
  361.     if (exidy440_firq_beam) result ^= 0x40;
  362.  
  363.     /* Whodunit needs the VBLANK bit mirrored to bit 0 */
  364.     if (mirror_vblank_bit && exidy440_firq_vblank) result ^= 0x01;
  365.  
  366.     /* Hit'N Miss needs the trigger bit mirrored to bit 0 */
  367.     if (mirror_trigger_bit) result = (result & 0xfe) | ((result >> 1) & 1);
  368.  
  369.     /* return with the appropriate XOR */
  370.     return result ^ port_0_xor;
  371. }
  372.  
  373.  
  374.  
  375. /*************************************
  376.  *
  377.  *    Banked RAM (actually EEROM)
  378.  *
  379.  *************************************/
  380.  
  381. static WRITE_HANDLER( bankram_w )
  382. {
  383.     /* EEROM lives in the upper 8k of bank 15 */
  384.     if (exidy440_bank == 15 && offset >= 0x2000)
  385.     {
  386.         memory_region(REGION_CPU1)[0x10000 + 15 * 0x4000 + offset] = data;
  387.         logerror("W EEROM[%04X] = %02X\n", offset - 0x2000, data);
  388.     }
  389.  
  390.     /* everything else is ROM and we ignore it */
  391. }
  392.  
  393.  
  394.  
  395. /*************************************
  396.  *
  397.  *    Audio board I/O reads
  398.  *
  399.  *************************************/
  400.  
  401. static READ_HANDLER( io1_r )
  402. {
  403.     int result = 0xff;
  404.  
  405.     switch (offset & 0xe0)
  406.     {
  407.         case 0x00:                                        /* sound command */
  408.             result = exidy440_sound_command;
  409.             break;
  410.  
  411.         case 0x20:                                        /* coin bits I/O1 */
  412.             result = (input_port_3_r(offset) & 0xfc) | coin_state;
  413.             result ^= port_3_xor;
  414.  
  415.             /* sound command acknowledgements come on bit 3 here */
  416.             if (!exidy440_sound_command_ack)
  417.                 result ^= 0x08;
  418.  
  419.             /* I/O1 accesses clear the CIRQ flip/flop */
  420.             cpu_set_irq_line(0, 0, CLEAR_LINE);
  421.             break;
  422.  
  423.         case 0x40:                                        /* clear coin counters I/O2 */
  424.             result = 0xff;
  425.             break;
  426.  
  427.         case 0x60:                                        /* dip switches (8) */
  428.             result = input_port_1_r(offset);
  429.             break;
  430.  
  431.         case 0x80:                                        /* player control bits */
  432.             result = input_port_2_r(offset) ^ port_2_xor;
  433.             break;
  434.  
  435.         case 0xa0:                                        /* coin bits I/O3 */
  436.             result = (input_port_3_r(offset) & 0xfc) | coin_state;
  437.             result ^= port_3_xor;
  438.  
  439.             /* sound command acknowledgements come on bit 3 here */
  440.             if (exidy440_sound_command_ack)
  441.                 result ^= 0x08;
  442.             break;
  443.  
  444.         case 0xc0:
  445.             /* for Clay Pigeon and Top Secret */
  446.             if (offset < 0xc4)
  447.                 return copy_protection_read;
  448.  
  449.             /* for Top Secret only */
  450.             if (offset == 0xc5)
  451.                 return (input_port_5_r(offset) & 1) ? 0x01 : 0x02;
  452.             else if (offset == 0xc6)
  453.                 return input_port_4_r(offset);
  454.             else if (offset == 0xc7)
  455.                 return input_port_6_r(offset);
  456.             else
  457.                 return 0;
  458.     }
  459.  
  460.     return result;
  461. }
  462.  
  463.  
  464.  
  465. /*************************************
  466.  *
  467.  *    Audio board I/O writes
  468.  *
  469.  *************************************/
  470.  
  471. static void delayed_sound_command_w(int param)
  472. {
  473.     exidy440_sound_command = param;
  474.     exidy440_sound_command_ack = 0;
  475.  
  476.     /* cause an FIRQ on the sound CPU */
  477.     cpu_set_irq_line(1, 1, ASSERT_LINE);
  478. }
  479.  
  480.  
  481. static WRITE_HANDLER( io1_w )
  482. {
  483.     logerror("W I/O1[%02X]=%02X\n", offset, data);
  484.  
  485.     /* switch off the upper 4 bits of the offset */
  486.     switch (offset & 0xe0)
  487.     {
  488.         case 0x00:                                        /* sound command */
  489.             timer_set(TIME_NOW, data, delayed_sound_command_w);
  490.             break;
  491.  
  492.         case 0x20:                                        /* coin bits I/O1 */
  493.  
  494.             /* accesses here clear the CIRQ flip/flop */
  495.             cpu_set_irq_line(0, 0, CLEAR_LINE);
  496.             break;
  497.  
  498.         case 0x40:                                        /* clear coin counters I/O2 */
  499.             coin_state = 3;
  500.             break;
  501.  
  502.         case 0x60:                                        /* dip switches (8) */
  503.             break;
  504.  
  505.         case 0x80:                                        /* player control bits */
  506.             break;
  507.  
  508.         case 0xa0:                                        /* coin bits I/O3 */
  509.             break;
  510.  
  511.         case 0xc0:
  512.             /* for Top Secret only */
  513.             if (offset == 0xc1)
  514.                 topsecex_yscroll = data;
  515.             break;
  516.     }
  517. }
  518.  
  519.  
  520.  
  521. /*************************************
  522.  *
  523.  *    Game-specific handlers
  524.  *
  525.  *************************************/
  526.  
  527. READ_HANDLER( showdown_pld_trigger_r )
  528. {
  529.     /* bank 0 is where the PLD lives - a read here will set the trigger */
  530.     if (exidy440_bank == 0)
  531.         showdown_bank_triggered = 1;
  532.  
  533.     /* just return the value from the current bank */
  534.     return memory_region(REGION_CPU1)[0x10000 + exidy440_bank * 0x4000 + 0x0055 + offset];
  535. }
  536.  
  537.  
  538. READ_HANDLER( showdown_pld_select1_r )
  539. {
  540.     /* bank 0 is where the PLD lives - a read here after a trigger will set bank "1" */
  541.     if (exidy440_bank == 0 && showdown_bank_triggered)
  542.     {
  543.         static const UINT8 bankdata[0x18] =
  544.         {
  545.             0x15,0x40,0xc1,0x8d,0x4c,0x84,0x0e,0xce,
  546.             0x52,0xd0,0x99,0x48,0x80,0x09,0xc9,0x45,
  547.             0xc4,0x8e,0x5a,0x92,0x18,0xd8,0x51,0xc0
  548.         };
  549.  
  550.         /* clear the trigger and copy the expected 24 bytes to the RAM area */
  551.         showdown_bank_triggered = 0;
  552.         memcpy(&memory_region(REGION_CPU1)[0x10000], bankdata, 0x18);
  553.     }
  554.  
  555.     /* just return the value from the current bank */
  556.     return memory_region(REGION_CPU1)[0x10000 + exidy440_bank * 0x4000 + 0x00ed + offset];
  557. }
  558.  
  559.  
  560. READ_HANDLER( showdown_pld_select2_r )
  561. {
  562.     /* bank 0 is where the PLD lives - a read here after a trigger will set bank "2" */
  563.     if (exidy440_bank == 0 && showdown_bank_triggered)
  564.     {
  565.         static const UINT8 bankdata[0x18] =
  566.         {
  567.             0x11,0x51,0xc0,0x89,0x4d,0x85,0x0c,0xcc,
  568.             0x46,0xd2,0x98,0x59,0x91,0x08,0xc8,0x41,
  569.             0xc5,0x8c,0x4e,0x86,0x1a,0xda,0x50,0xd1
  570.         };
  571.  
  572.         /* clear the trigger and copy the expected 24 bytes to the RAM area */
  573.         showdown_bank_triggered = 0;
  574.         memcpy(&memory_region(REGION_CPU1)[0x10000], bankdata, 0x18);
  575.     }
  576.  
  577.     /* just return the value from the current bank */
  578.     return memory_region(REGION_CPU1)[0x10000 + exidy440_bank * 0x4000 + 0x1243 + offset];
  579. }
  580.  
  581.  
  582.  
  583. /*************************************
  584.  *
  585.  *    Main CPU memory handlers
  586.  *
  587.  *************************************/
  588.  
  589. static struct MemoryReadAddress readmem_cpu1[] =
  590. {
  591.     { 0x0000, 0x1fff, MRA_RAM },
  592.     { 0x2000, 0x209f, MRA_RAM },
  593.     { 0x20a0, 0x29ff, MRA_RAM },
  594.     { 0x2a00, 0x2aff, exidy440_videoram_r },
  595.     { 0x2b00, 0x2b00, exidy440_vertical_pos_r },
  596.     { 0x2b01, 0x2b01, exidy440_horizontal_pos_r },
  597.     { 0x2b02, 0x2b02, MRA_RAM },
  598.     { 0x2b03, 0x2b03, input_r },
  599.     { 0x2c00, 0x2dff, exidy440_paletteram_r },
  600.     { 0x2e00, 0x2eff, io1_r },
  601.     { 0x3000, 0x3fff, MRA_RAM },
  602.     { 0x4000, 0x7fff, MRA_BANK1 },
  603.     { 0x8000, 0xffff, MRA_ROM },
  604.     { -1 }  /* end of table */
  605. };
  606.  
  607.  
  608. static struct MemoryWriteAddress writemem_cpu1[] =
  609. {
  610.     { 0x0000, 0x1fff, MWA_RAM, &exidy440_imageram },
  611.     { 0x2000, 0x209f, MWA_RAM, &spriteram },
  612.     { 0x20a0, 0x29ff, MWA_RAM },
  613.     { 0x2a00, 0x2aff, exidy440_videoram_w },
  614.     { 0x2b01, 0x2b01, exidy440_interrupt_clear_w },
  615.     { 0x2b02, 0x2b02, MWA_RAM, &exidy440_scanline },
  616.     { 0x2b03, 0x2b03, exidy440_control_w },
  617.     { 0x2c00, 0x2dff, exidy440_paletteram_w },
  618.     { 0x2e00, 0x2eff, io1_w },
  619.     { 0x3000, 0x3fff, MWA_RAM },
  620.     { 0x4000, 0x7fff, bankram_w },
  621.     { 0x8000, 0xffff, MWA_ROM },
  622.     { -1 }  /* end of table */
  623. };
  624.  
  625.  
  626.  
  627. /*************************************
  628.  *
  629.  *    Sound CPU memory handlers
  630.  *
  631.  *************************************/
  632.  
  633. static struct MemoryReadAddress readmem_cpu2[] =
  634. {
  635.     { 0x8000, 0x8016, exidy440_m6844_r },
  636.     { 0x8400, 0x8407, MRA_RAM },
  637.     { 0x8800, 0x8800, exidy440_sound_command_r },
  638.     { 0x9800, 0x9800, MRA_NOP },
  639.     { 0xa000, 0xbfff, MRA_RAM },
  640.     { 0xe000, 0xffff, MRA_ROM },
  641.     { -1 }  /* end of table */
  642. };
  643.  
  644.  
  645. static struct MemoryWriteAddress writemem_cpu2[] =
  646. {
  647.     { 0x8000, 0x8016, exidy440_m6844_w, &exidy440_m6844_data },
  648.     { 0x8400, 0x8407, exidy440_sound_volume_w, &exidy440_sound_volume },
  649.     { 0x9400, 0x9403, MWA_RAM, &exidy440_sound_banks },
  650.     { 0x9800, 0x9800, exidy440_sound_interrupt_clear_w },
  651.     { 0xa000, 0xbfff, MWA_RAM },
  652.     { 0xe000, 0xffff, MWA_ROM },
  653.     { -1 }  /* end of table */
  654. };
  655.  
  656.  
  657.  
  658. /*************************************
  659.  *
  660.  *    Port definitions
  661.  *
  662.  *************************************/
  663.  
  664. #define COINAGE \
  665.     PORT_DIPNAME( 0x0f, 0x0f, DEF_STR( Coinage ) ) \
  666.     PORT_DIPSETTING(    0x03, DEF_STR( 4C_1C ) ) \
  667.     PORT_DIPSETTING(    0x07, DEF_STR( 3C_1C ) ) \
  668.     PORT_DIPSETTING(    0x02, DEF_STR( 4C_2C ) ) \
  669.     PORT_DIPSETTING(    0x0b, DEF_STR( 2C_1C ) ) \
  670.     PORT_DIPSETTING(    0x06, DEF_STR( 3C_2C ) ) \
  671.     PORT_DIPSETTING(    0x01, DEF_STR( 4C_3C ) ) \
  672.     PORT_DIPSETTING(    0x00, DEF_STR( 4C_4C ) ) \
  673.     PORT_DIPSETTING(    0x05, DEF_STR( 3C_3C ) ) \
  674.     PORT_DIPSETTING(    0x0a, DEF_STR( 2C_2C ) ) \
  675.     PORT_DIPSETTING(    0x0f, DEF_STR( 1C_1C ) ) \
  676.     PORT_DIPSETTING(    0x04, DEF_STR( 3C_4C ) ) \
  677.     PORT_DIPSETTING(    0x09, DEF_STR( 2C_3C ) ) \
  678.     PORT_DIPSETTING(    0x08, DEF_STR( 2C_4C ) ) \
  679.     PORT_DIPSETTING(    0x0e, DEF_STR( 1C_2C ) ) \
  680.     PORT_DIPSETTING(    0x0d, DEF_STR( 1C_3C ) ) \
  681.     PORT_DIPSETTING(    0x0c, DEF_STR( 1C_4C ) )
  682.  
  683.  
  684. INPUT_PORTS_START( crossbow )
  685.     PORT_START                /* player inputs and logic board dips */
  686.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  687.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  688.     PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Lives ) )
  689.     PORT_DIPSETTING(    0x08, "2" )
  690.     PORT_DIPSETTING(    0x0c, "3" )
  691.     PORT_DIPSETTING(    0x04, "4" )
  692.     PORT_DIPSETTING(    0x00, "5" )
  693.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  694.     PORT_DIPSETTING(    0x00, "Easy" )
  695.     PORT_DIPSETTING(    0x30, "Normal" )
  696.     PORT_DIPSETTING(    0x20, "Hard" )
  697.     PORT_DIPSETTING(    0x10, "Hardest" )
  698.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  699.  
  700.     PORT_START                 /* audio board dips */
  701.     COINAGE
  702.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  703.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Free_Play ) )
  704.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  705.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  706.  
  707.     PORT_START                /* start button */
  708.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  709.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  710.  
  711.     PORT_START                /* coin counters */
  712.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  713.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  714.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  715.  
  716.     PORT_START                /* fake analog X */
  717.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  718.  
  719.     PORT_START                /* fake analog Y */
  720.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  721. INPUT_PORTS_END
  722.  
  723.  
  724. INPUT_PORTS_START( cheyenne )
  725.     PORT_START                /* player inputs and logic board dips */
  726.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  727.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  728.     PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Lives ) )
  729.     PORT_DIPSETTING(    0x08, "2" )
  730.     PORT_DIPSETTING(    0x0c, "3" )
  731.     PORT_DIPSETTING(    0x04, "4" )
  732.     PORT_DIPSETTING(    0x00, "5" )
  733.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  734.     PORT_DIPSETTING(    0x00, "Easy" )
  735.     PORT_DIPSETTING(    0x30, "Normal" )
  736.     PORT_DIPSETTING(    0x20, "Hard" )
  737.     PORT_DIPSETTING(    0x10, "Hardest" )
  738.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  739.  
  740.     PORT_START                 /* audio board dips */
  741.     COINAGE
  742.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  743.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Free_Play ) )
  744.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  745.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  746.  
  747.     PORT_START                /* start button */
  748.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  749.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  750.  
  751.     PORT_START                /* coin counters */
  752.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  753.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  754.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  755.  
  756.     PORT_START                /* fake analog X */
  757.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  758.  
  759.     PORT_START                /* fake analog Y */
  760.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  761. INPUT_PORTS_END
  762.  
  763.  
  764. INPUT_PORTS_START( combat )
  765.     PORT_START                /* player inputs and logic board dips */
  766.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  767.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  768.     PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Lives ) )
  769.     PORT_DIPSETTING(    0x08, "2" )
  770.     PORT_DIPSETTING(    0x0c, "3" )
  771.     PORT_DIPSETTING(    0x04, "4" )
  772.     PORT_DIPSETTING(    0x00, "5" )
  773.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  774.     PORT_DIPSETTING(    0x00, "Easy" )
  775.     PORT_DIPSETTING(    0x30, "Normal" )
  776.     PORT_DIPSETTING(    0x20, "Hard" )
  777.     PORT_DIPSETTING(    0x10, "Hardest" )
  778.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  779.  
  780.     PORT_START                 /* audio board dips */
  781.     COINAGE
  782.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  783.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Free_Play ) )
  784.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  785.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  786.  
  787.     PORT_START                /* start button */
  788.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  789.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  790.  
  791.     PORT_START                /* coin counters */
  792.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  793.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  794.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  795.  
  796.     PORT_START                /* fake analog X */
  797.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  798.  
  799.     PORT_START                /* fake analog Y */
  800.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  801. INPUT_PORTS_END
  802.  
  803.  
  804. INPUT_PORTS_START( cracksht )
  805.     PORT_START                /* player inputs and logic board dips */
  806.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  807.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  808.     PORT_DIPNAME( 0x0c, 0x0c, "Seconds" )
  809.     PORT_DIPSETTING(    0x08, "20" )
  810.     PORT_DIPSETTING(    0x0c, "30" )
  811.     PORT_DIPSETTING(    0x04, "40" )
  812.     PORT_DIPSETTING(    0x00, "50" )
  813.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  814.     PORT_DIPSETTING(    0x00, "Easy" )
  815.     PORT_DIPSETTING(    0x30, "Normal" )
  816.     PORT_DIPSETTING(    0x20, "Hard" )
  817.     PORT_DIPSETTING(    0x10, "Hardest" )
  818.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  819.  
  820.     PORT_START                 /* audio board dips */
  821.     COINAGE
  822.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  823.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) )
  824.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  825.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  826.  
  827.     PORT_START                /* start button */
  828.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  829.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  830.  
  831.     PORT_START                /* coin counters */
  832.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  833.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  834.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  835.  
  836.     PORT_START                /* fake analog X */
  837.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  838.  
  839.     PORT_START                /* fake analog Y */
  840.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  841. INPUT_PORTS_END
  842.  
  843.  
  844. INPUT_PORTS_START( claypign )
  845.     PORT_START                /* player inputs and logic board dips */
  846.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  847.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  848.     PORT_BIT( 0x0c, IP_ACTIVE_LOW, IPT_UNKNOWN )
  849.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  850.     PORT_DIPSETTING(    0x00, "Easy" )
  851.     PORT_DIPSETTING(    0x30, "Normal" )
  852.     PORT_DIPSETTING(    0x20, "Hard" )
  853.     PORT_DIPSETTING(    0x10, "Hardest" )
  854.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  855.  
  856.     PORT_START                 /* audio board dips */
  857.     COINAGE
  858.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  859.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Unknown ) )
  860.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  861.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  862.  
  863.     PORT_START                /* start button */
  864.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  865.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  866.  
  867.     PORT_START                /* coin counters */
  868.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  869.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  870.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  871.  
  872.     PORT_START                /* fake analog X */
  873.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  874.  
  875.     PORT_START                /* fake analog Y */
  876.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  877. INPUT_PORTS_END
  878.  
  879.  
  880. INPUT_PORTS_START( chiller )
  881.     PORT_START                /* player inputs and logic board dips */
  882.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  883.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  884.     PORT_DIPNAME( 0x0c, 0x0c, "Seconds" )
  885.     PORT_DIPSETTING(    0x08, "30" )
  886.     PORT_DIPSETTING(    0x0c, "45" )
  887.     PORT_DIPSETTING(    0x04, "60" )
  888.     PORT_DIPSETTING(    0x00, "70" )
  889.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  890.     PORT_DIPSETTING(    0x00, "Easy" )
  891.     PORT_DIPSETTING(    0x30, "Normal" )
  892.     PORT_DIPSETTING(    0x20, "Hard" )
  893.     PORT_DIPSETTING(    0x10, "Hardest" )
  894.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  895.  
  896.     PORT_START                 /* audio board dips */
  897.     COINAGE
  898.     PORT_BIT( 0xf0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  899.  
  900.     PORT_START                /* start button */
  901.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  902.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  903.  
  904.     PORT_START                /* coin counters */
  905.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  906.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  907.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  908.  
  909.     PORT_START                /* fake analog X */
  910.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  911.  
  912.     PORT_START                /* fake analog Y */
  913.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  914. INPUT_PORTS_END
  915.  
  916.  
  917. INPUT_PORTS_START( topsecex )
  918.     PORT_START                /* player inputs and logic board dips */
  919.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  920.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_UNKNOWN )
  921.     PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Lives ) )
  922.     PORT_DIPSETTING(    0x08, "3" )
  923.     PORT_DIPSETTING(    0x0c, "4" )
  924.     PORT_DIPSETTING(    0x04, "5" )
  925.     PORT_DIPSETTING(    0x00, "6" )
  926.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  927.     PORT_DIPSETTING(    0x00, "Easy" )
  928.     PORT_DIPSETTING(    0x30, "Normal" )
  929.     PORT_DIPSETTING(    0x20, "Hard" )
  930.     PORT_DIPSETTING(    0x10, "Hardest" )
  931.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  932.  
  933.     PORT_START                 /* audio board dips */
  934.     COINAGE
  935.     PORT_BIT( 0xf0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  936.  
  937.     PORT_START                /* start button */
  938.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_BUTTON2 )
  939.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  940.  
  941.     PORT_START                /* coin counters */
  942.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  943.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  944.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  945.  
  946.     PORT_START                /* fake analog X */
  947.     PORT_ANALOG( 0xff, 0x00, IPT_TRACKBALL_X | IPF_REVERSE, 50, 10, -127, 127 )
  948.  
  949.     PORT_START                /* fake analog Y */
  950.     PORT_BIT(  0xff, IP_ACTIVE_LOW, IPT_BUTTON1 )
  951.  
  952.     PORT_START                /* start button */
  953.     PORT_BITX( 0x01, IP_ACTIVE_LOW, IPT_BUTTON3, "Fireball", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  954.     PORT_BITX( 0x02, IP_ACTIVE_LOW, IPT_BUTTON4, "Laser", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  955.     PORT_BITX( 0x04, IP_ACTIVE_LOW, IPT_BUTTON5, "Missile", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  956.     PORT_BITX( 0x08, IP_ACTIVE_LOW, IPT_BUTTON6, "Oil", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  957.     PORT_BITX( 0x10, IP_ACTIVE_LOW, IPT_BUTTON7, "Turbo", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  958.     PORT_BITX( 0x20, IP_ACTIVE_LOW, IPT_BUTTON8, "Shield", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  959.     PORT_BIT(  0x40, IP_ACTIVE_LOW, IPT_UNKNOWN )
  960.     PORT_BITX( 0x80, IP_ACTIVE_LOW, IPT_START1, "Top Secret", IP_KEY_DEFAULT, IP_JOY_DEFAULT )
  961. INPUT_PORTS_END
  962.  
  963.  
  964. INPUT_PORTS_START( hitnmiss )
  965.     PORT_START                /* player inputs and logic board dips */
  966.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  967.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  968.     PORT_DIPNAME( 0x0c, 0x0c, "Seconds" )
  969.     PORT_DIPSETTING(    0x08, "20" )
  970.     PORT_DIPSETTING(    0x0c, "30" )
  971.     PORT_DIPSETTING(    0x04, "40" )
  972.     PORT_DIPSETTING(    0x00, "50" )
  973.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  974.     PORT_DIPSETTING(    0x00, "Easy" )
  975.     PORT_DIPSETTING(    0x30, "Normal" )
  976.     PORT_DIPSETTING(    0x20, "Hard" )
  977.     PORT_DIPSETTING(    0x10, "Hardest" )
  978.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  979.  
  980.     PORT_START                 /* audio board dips */
  981.     COINAGE
  982.     PORT_BIT( 0x70, IP_ACTIVE_LOW, IPT_UNKNOWN )
  983.     PORT_DIPNAME( 0x80, 0x80, DEF_STR( Free_Play ) )
  984.     PORT_DIPSETTING(    0x80, DEF_STR( Off ) )
  985.     PORT_DIPSETTING(    0x00, DEF_STR( On ) )
  986.  
  987.     PORT_START                /* start button */
  988.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  989.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  990.  
  991.     PORT_START                /* coin counters */
  992.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  993.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  994.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  995.  
  996.     PORT_START                /* fake analog X */
  997.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  998.  
  999.     PORT_START                /* fake analog Y */
  1000.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  1001. INPUT_PORTS_END
  1002.  
  1003.  
  1004. INPUT_PORTS_START( whodunit )
  1005.     PORT_START                /* player inputs and logic board dips */
  1006.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1007.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  1008.     PORT_DIPNAME( 0x0c, 0x0c, DEF_STR( Lives ) )
  1009.     PORT_DIPSETTING(    0x08, "2" )
  1010.     PORT_DIPSETTING(    0x0c, "3" )
  1011.     PORT_DIPSETTING(    0x04, "4" )
  1012.     PORT_DIPSETTING(    0x00, "5" )
  1013.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  1014.     PORT_DIPSETTING(    0x00, "Easy" )
  1015.     PORT_DIPSETTING(    0x30, "Normal" )
  1016.     PORT_DIPSETTING(    0x20, "Hard" )
  1017.     PORT_DIPSETTING(    0x10, "Hardest" )
  1018.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1019.  
  1020.     PORT_START                 /* audio board dips */
  1021.     COINAGE
  1022.     PORT_BIT( 0xf0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1023.  
  1024.     PORT_START                /* start button */
  1025.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  1026.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1027.  
  1028.     PORT_START                /* coin counters */
  1029.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  1030.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  1031.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1032.  
  1033.     PORT_START                /* fake analog X */
  1034.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  1035.  
  1036.     PORT_START                /* fake analog Y */
  1037.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  1038. INPUT_PORTS_END
  1039.  
  1040.  
  1041. INPUT_PORTS_START( showdown )
  1042.     PORT_START                /* player inputs and logic board dips */
  1043.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1044.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_BUTTON1 )
  1045.     PORT_DIPNAME( 0x0c, 0x0c, "Hands" )
  1046.     PORT_DIPSETTING(    0x08, "1" )
  1047.     PORT_DIPSETTING(    0x0c, "2" )
  1048.     PORT_DIPSETTING(    0x04, "3" )
  1049.     PORT_DIPSETTING(    0x00, "4" )
  1050.     PORT_DIPNAME( 0x30, 0x30, DEF_STR( Difficulty ) )
  1051.     PORT_DIPSETTING(    0x00, "Easy" )
  1052.     PORT_DIPSETTING(    0x30, "Normal" )
  1053.     PORT_DIPSETTING(    0x20, "Hard" )
  1054.     PORT_DIPSETTING(    0x10, "Hardest" )
  1055.     PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1056.  
  1057.     PORT_START                 /* audio board dips */
  1058.     COINAGE
  1059.     PORT_BIT( 0xf0, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1060.  
  1061.     PORT_START                /* start button */
  1062.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_START1 )
  1063.     PORT_BIT( 0xfe, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1064.  
  1065.     PORT_START                /* coin counters */
  1066.     PORT_BIT( 0x01, IP_ACTIVE_LOW, IPT_COIN1 )
  1067.     PORT_BIT( 0x02, IP_ACTIVE_LOW, IPT_COIN2 )
  1068.     PORT_BIT( 0xfc, IP_ACTIVE_LOW, IPT_UNKNOWN )
  1069.  
  1070.     PORT_START                /* fake analog X */
  1071.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_X, 50, 10, 0, 255 )
  1072.  
  1073.     PORT_START                /* fake analog Y */
  1074.     PORT_ANALOG( 0xff, 0x80, IPT_AD_STICK_Y, 70, 10, 0, 255 )
  1075. INPUT_PORTS_END
  1076.  
  1077.  
  1078.  
  1079. /*************************************
  1080.  *
  1081.  *    Sound definitions
  1082.  *
  1083.  *************************************/
  1084.  
  1085. static struct CustomSound_interface custom_interface =
  1086. {
  1087.     exidy440_sh_start,
  1088.     exidy440_sh_stop,
  1089.     exidy440_sh_update
  1090. };
  1091.  
  1092.  
  1093.  
  1094. /*************************************
  1095.  *
  1096.  *    Machine driver
  1097.  *
  1098.  *************************************/
  1099.  
  1100. static struct MachineDriver machine_driver_exidy440 =
  1101. {
  1102.     /* basic machine hardware */
  1103.     {
  1104.         {
  1105.             CPU_M6809,
  1106.             12979200/8,                     /* 12Mhz/8 */
  1107.             readmem_cpu1,writemem_cpu1,0,0,
  1108.             main_interrupt,1
  1109.         },
  1110.         {
  1111.             CPU_M6809 | CPU_AUDIO_CPU,
  1112.             12979200/4/4,                   /* 12MHz/4 into XTAL, which is 4x clock */
  1113.             readmem_cpu2,writemem_cpu2,0,0,
  1114.             exidy440_sound_interrupt,1
  1115.         }
  1116.     },
  1117.     60, DEFAULT_REAL_60HZ_VBLANK_DURATION,    /* frames per second, vblank duration */
  1118.     1,
  1119.     init_machine,
  1120.  
  1121.     /* video hardware */
  1122.     320, 240, { 0, 319, 0, 239 },
  1123.     0,
  1124.     257, 512,
  1125.     0,
  1126.  
  1127.     VIDEO_TYPE_RASTER | VIDEO_MODIFIES_PALETTE,
  1128.     0,
  1129.     exidy440_vh_start,
  1130.     exidy440_vh_stop,
  1131.     exidy440_vh_screenrefresh,
  1132.  
  1133.     /* sound hardware */
  1134.     SOUND_SUPPORTS_STEREO,0,0,0,
  1135.     {
  1136.         {
  1137.             SOUND_CUSTOM,
  1138.             &custom_interface
  1139.         }
  1140.     },
  1141.  
  1142.     nvram_handler
  1143. };
  1144.  
  1145.  
  1146.  
  1147. /*************************************
  1148.  *
  1149.  *    Driver initialization
  1150.  *
  1151.  *************************************/
  1152.  
  1153. #define SET_PARAMS(top,p0,p2,p3,mv,mt,cpr) \
  1154.     exidy440_topsecret         = top;\
  1155.     port_0_xor                 = p0;\
  1156.     port_2_xor                 = p2;\
  1157.     port_3_xor                = p3;\
  1158.     mirror_vblank_bit         = mv;\
  1159.     mirror_trigger_bit         = mt;\
  1160.     copy_protection_read     = cpr
  1161.  
  1162. static void init_crossbow(void) { SET_PARAMS(0, 0x00, 0x00, 0x00, 0, 0, 0x00); }
  1163. static void init_cheyenne(void) { SET_PARAMS(0, 0xff, 0x00, 0x00, 0, 0, 0x00); }
  1164. static void init_combat  (void)   { SET_PARAMS(0, 0xff, 0xff, 0x00, 0, 0, 0x00); }
  1165. static void init_cracksht(void) { SET_PARAMS(0, 0xff, 0xff, 0x04, 0, 0, 0x00); }
  1166. static void init_claypign(void) { SET_PARAMS(0, 0xff, 0xff, 0x04, 0, 0, 0x76); }
  1167. static void init_chiller (void)  { SET_PARAMS(0, 0xff, 0xff, 0x04, 0, 0, 0x00); }
  1168. static void init_topsecex(void) { SET_PARAMS(1, 0xff, 0xff, 0x04, 0, 0, 0x00); }
  1169. static void init_hitnmiss(void) { SET_PARAMS(0, 0xff, 0xff, 0x04, 0, 1, 0x00); }
  1170. static void init_whodunit(void) { SET_PARAMS(0, 0xff, 0xff, 0x04, 1, 0, 0x00); }
  1171. static void init_showdown(void)
  1172. {
  1173.     SET_PARAMS(0, 0xff, 0xff, 0x04, 0, 0, 0x00);
  1174.  
  1175.     /* set up the fake PLD */
  1176.     showdown_bank_triggered = 0;
  1177.     install_mem_read_handler(0, 0x4055, 0x4055, showdown_pld_trigger_r);
  1178.     install_mem_read_handler(0, 0x40ed, 0x40ed, showdown_pld_select1_r);
  1179.     install_mem_read_handler(0, 0x5243, 0x5243, showdown_pld_select2_r);
  1180.  
  1181.     /* ensure that we're triggered to bank "1" to start */
  1182.     exidy440_bank = 0;
  1183.     showdown_pld_trigger_r(0);
  1184.     showdown_pld_select1_r(0);
  1185. }
  1186.  
  1187.  
  1188.  
  1189. /*************************************
  1190.  *
  1191.  *    ROM definitions
  1192.  *
  1193.  *************************************/
  1194.  
  1195. ROM_START( crossbow )
  1196.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1197.     ROM_LOAD( "xbl-2.1a",   0x08000, 0x2000, 0xbd53ac46 )
  1198.     ROM_LOAD( "xbl-2.3a",   0x0a000, 0x2000, 0x703e1376 )
  1199.     ROM_LOAD( "xbl-2.4a",   0x0c000, 0x2000, 0x52c5daa1 )
  1200.     ROM_LOAD( "xbl-2.6a",   0x0e000, 0x2000, 0xf42a68f7 )
  1201.     ROM_LOAD( "xbl-1.1e",   0x10000, 0x2000, 0x2834258e )
  1202.     ROM_LOAD( "xbl-1.3e",   0x12000, 0x2000, 0x587b186c )
  1203.     ROM_LOAD( "xbl-1.4e",   0x14000, 0x2000, 0x23fbfa8e )
  1204.     ROM_LOAD( "xbl-1.6e",   0x16000, 0x2000, 0xa3ebcc92 )
  1205.     ROM_LOAD( "xbl-1.7e",   0x18000, 0x2000, 0x945b3a68 )
  1206.     ROM_LOAD( "xbl-1.8e",   0x1a000, 0x2000, 0x0d1c5d24 )
  1207.     ROM_LOAD( "xbl-1.10e",  0x1c000, 0x2000, 0xca30788b )
  1208.     ROM_LOAD( "xbl-1.11e",  0x1e000, 0x2000, 0x6661c5ee )
  1209.     ROM_LOAD( "xbl-1.1d",   0x20000, 0x2000, 0xa1416191 )
  1210.     ROM_LOAD( "xbl-1.3d",   0x22000, 0x2000, 0x7322b5e1 )
  1211.     ROM_LOAD( "xbl-1.4d",   0x24000, 0x2000, 0x425d51ef )
  1212.     ROM_LOAD( "xbl-1.6d",   0x26000, 0x2000, 0xc923c9f5 )
  1213.     ROM_LOAD( "xbl-1.7d",   0x28000, 0x2000, 0x46cdf117 )
  1214.     ROM_LOAD( "xbl-1.8d",   0x2a000, 0x2000, 0x62bad9b6 )
  1215.     ROM_LOAD( "xbl-1.10d",  0x2c000, 0x2000, 0xd4aaa382 )
  1216.     ROM_LOAD( "xbl-1.11d",  0x2e000, 0x2000, 0xefc77790 )
  1217.     ROM_LOAD( "xbl-1.1c",   0x30000, 0x2000, 0xdbbd35cb )
  1218.     ROM_LOAD( "xbl-1.3c",   0x32000, 0x2000, 0xf011f98d )
  1219.     ROM_LOAD( "xbl-1.4c",   0x34000, 0x2000, 0x1257b947 )
  1220.     ROM_LOAD( "xbl-1.6c",   0x36000, 0x2000, 0x48da9081 )
  1221.     ROM_LOAD( "xbl-1.7c",   0x38000, 0x2000, 0x8d4d4855 )
  1222.     ROM_LOAD( "xbl-1.8c",   0x3a000, 0x2000, 0x4c52b85a )
  1223.     ROM_LOAD( "xbl-1.10c",  0x3c000, 0x2000, 0x5986130b )
  1224.     ROM_LOAD( "xbl-1.11c",  0x3e000, 0x2000, 0x163a6ae0 )
  1225.     ROM_LOAD( "xbl-1.1b",   0x40000, 0x2000, 0x36ea0269 )
  1226.     ROM_LOAD( "xbl-1.3b",   0x42000, 0x2000, 0x4a03c2c9 )
  1227.     ROM_LOAD( "xbl-1.4b",   0x44000, 0x2000, 0x7e21c624 )
  1228.  
  1229.     ROM_REGION( 0x10000, REGION_CPU2 )
  1230.     ROM_LOAD( "xba-11.1h",  0x0e000, 0x2000, 0x1b61d0c1 )
  1231.  
  1232.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1233.     ROM_LOAD( "xba-1.2k",   0x00000, 0x2000, 0xb6e57685 )
  1234.     ROM_LOAD( "xba-1.2l",   0x02000, 0x2000, 0x2c24cb35 )
  1235.     ROM_LOAD( "xba-1.2m",   0x04000, 0x2000, 0xf3a4f2be )
  1236.     ROM_LOAD( "xba-1.2n",   0x06000, 0x2000, 0x15cf362d )
  1237.     ROM_LOAD( "xba-1.2p",   0x08000, 0x2000, 0x56f53af9 )
  1238.     ROM_LOAD( "xba-1.2r",   0x0a000, 0x2000, 0x3d8277b0 )
  1239.     ROM_LOAD( "xba-1.2s",   0x0c000, 0x2000, 0x14dd8993 )
  1240.     ROM_LOAD( "xba-1.2t",   0x0e000, 0x2000, 0xdfa783e4 )
  1241.     ROM_LOAD( "xba-1.1k",   0x10000, 0x2000, 0x4f01f9e6 )
  1242.     ROM_LOAD( "xba-1.1l",   0x12000, 0x2000, 0xfb119acf )
  1243.     ROM_LOAD( "xba-1.1m",   0x14000, 0x2000, 0x18d097ac )
  1244.     ROM_LOAD( "xba-1.1n",   0x16000, 0x2000, 0x2e855698 )
  1245.     ROM_LOAD( "xba-1.1p",   0x18000, 0x2000, 0x788bfac6 )
  1246.     ROM_LOAD( "xba-1.1r",   0x1a000, 0x2000, 0xb8ec43b3 )
  1247.     ROM_LOAD( "xba-1.1s",   0x1c000, 0x2000, 0xc9ead134 )
  1248.     ROM_LOAD( "xba-1.1t",   0x1e000, 0x2000, 0x5f41c282 )
  1249. ROM_END
  1250.  
  1251.  
  1252. ROM_START( cheyenne )
  1253.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1254.     ROM_LOAD( "cyl-1.1a",   0x08000, 0x2000, 0x504c3fa6 )
  1255.     ROM_LOAD( "cyl-1.3a",   0x0a000, 0x2000, 0x09b7903b )
  1256.     ROM_LOAD( "cyl-1.4a",   0x0c000, 0x2000, 0xb708646b )
  1257.     ROM_LOAD( "cyl-1.6a",   0x0e000, 0x2000, 0x5d1e708d )
  1258.     ROM_LOAD( "cyl-1.1e",   0x10000, 0x2000, 0x8778e317 )
  1259.     ROM_LOAD( "cyl-1.3e",   0x12000, 0x2000, 0xc8a9ca1b )
  1260.     ROM_LOAD( "cyl-1.4e",   0x14000, 0x2000, 0x86c4125a )
  1261.     ROM_LOAD( "cyl-1.6e",   0x16000, 0x2000, 0x51f4f060 )
  1262.     ROM_LOAD( "cyl-1.7e",   0x18000, 0x2000, 0x4924d0c1 )
  1263.     ROM_LOAD( "cyl-1.8e",   0x1a000, 0x2000, 0x5c7c4dd7 )
  1264.     ROM_LOAD( "cyl-1.10e",  0x1c000, 0x2000, 0x57232888 )
  1265.     ROM_LOAD( "cyl-1.11e",  0x1e000, 0x2000, 0x2a767252 )
  1266.     ROM_LOAD( "cyl-1.1d",   0x20000, 0x2000, 0xcd590e99 )
  1267.     ROM_LOAD( "cyl-1.3d",   0x22000, 0x2000, 0x1fddccdb )
  1268.     ROM_LOAD( "cyl-1.4d",   0x24000, 0x2000, 0x6c5ee6d7 )
  1269.     ROM_LOAD( "cyl-1.6d",   0x26000, 0x2000, 0x0e7c16c2 )
  1270.     ROM_LOAD( "cyl-1.7d",   0x28000, 0x2000, 0xabe11728 )
  1271.     ROM_LOAD( "cyl-1.8d",   0x2a000, 0x2000, 0x95bb9a72 )
  1272.     ROM_LOAD( "cyl-1.10d",  0x2c000, 0x2000, 0x5bc251be )
  1273.     ROM_LOAD( "cyl-1.7c",   0x38000, 0x2000, 0xe9f6ce96 )
  1274.     ROM_LOAD( "cyl-1.8c",   0x3a000, 0x2000, 0xcb3f8e9e )
  1275.     ROM_LOAD( "cyl-1.10c",  0x3c000, 0x2000, 0x49f90633 )
  1276.     ROM_LOAD( "cyl-1.11c",  0x3e000, 0x2000, 0x70b69cf1 )
  1277.     ROM_LOAD( "cyl-1.1b",   0x40000, 0x2000, 0xc372e018 )
  1278.     ROM_LOAD( "cyl-1.3b",   0x42000, 0x2000, 0x6a583feb )
  1279.     ROM_LOAD( "cyl-1.4b",   0x44000, 0x2000, 0x670e127d )
  1280.     ROM_LOAD( "cyl-1.6b",   0x46000, 0x2000, 0xed245268 )
  1281.     ROM_LOAD( "cyl-1.7b",   0x48000, 0x2000, 0xdcc56d6c )
  1282.     ROM_LOAD( "cyl-1.8b",   0x4a000, 0x2000, 0xc0653d3e )
  1283.     ROM_LOAD( "cyl-1.10b",  0x4c000, 0x2000, 0x7fc67d19 )
  1284.  
  1285.     ROM_REGION( 0x10000, REGION_CPU2 )
  1286.     ROM_LOAD( "cya-1.1h",   0x0e000, 0x2000, 0x5aed3d8c )
  1287.  
  1288.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1289.     ROM_LOAD( "cya-1.2k",   0x00000, 0x2000, 0xdc2b716d )
  1290.     ROM_LOAD( "cya-1.2l",   0x02000, 0x2000, 0x091ad047 )
  1291.     ROM_LOAD( "cya-1.2m",   0x04000, 0x2000, 0x59085362 )
  1292.     ROM_LOAD( "cya-1.2n",   0x06000, 0x2000, 0x9c2e23c7 )
  1293.     ROM_LOAD( "cya-1.2p",   0x08000, 0x2000, 0xeff18766 )
  1294.     ROM_LOAD( "cya-1.2r",   0x0a000, 0x2000, 0x8e730c98 )
  1295.     ROM_LOAD( "cya-1.2s",   0x0c000, 0x2000, 0x46515454 )
  1296.     ROM_LOAD( "cya-1.2t",   0x0e000, 0x2000, 0x5868fa84 )
  1297.     ROM_LOAD( "cya-1.1k",   0x10000, 0x2000, 0x45a306a6 )
  1298.     ROM_LOAD( "cya-1.1l",   0x12000, 0x2000, 0x3c7e2127 )
  1299.     ROM_LOAD( "cya-1.1m",   0x14000, 0x2000, 0x39ddc9f7 )
  1300.     ROM_LOAD( "cya-1.1n",   0x16000, 0x2000, 0x5fcee4fd )
  1301.     ROM_LOAD( "cya-1.1p",   0x18000, 0x2000, 0x81a4a876 )
  1302.     ROM_LOAD( "cya-1.1r",   0x1a000, 0x2000, 0xdfd84e73 )
  1303. ROM_END
  1304.  
  1305.  
  1306. ROM_START( combat )
  1307.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1308.     ROM_LOAD( "1a",   0x08000, 0x2000, 0x159a573b )
  1309.     ROM_LOAD( "3a",   0x0a000, 0x2000, 0x59ae51a7 )
  1310.     ROM_LOAD( "4a",   0x0c000, 0x2000, 0x95a1f3d0 )
  1311.     ROM_LOAD( "6a",   0x0e000, 0x2000, 0xaf3fef5f )
  1312.     ROM_LOAD( "6d",   0x26000, 0x2000, 0x43d3eb61 )
  1313.     ROM_LOAD( "7d",   0x28000, 0x2000, 0xef31659c )
  1314.     ROM_LOAD( "8d",   0x2a000, 0x2000, 0xfb29c5cd )
  1315.     ROM_LOAD( "10d",  0x2c000, 0x2000, 0x2ca0eaa4 )
  1316.     ROM_LOAD( "11d",  0x2e000, 0x2000, 0xcc9f2001 )
  1317.     ROM_LOAD( "1c",   0x30000, 0x2000, 0xb7b9c5ad )
  1318.     ROM_LOAD( "3c",   0x32000, 0x2000, 0xb700e6ec )
  1319.     ROM_LOAD( "4c",   0x34000, 0x2000, 0x89fc2b2d )
  1320.     ROM_LOAD( "6c",   0x36000, 0x2000, 0x6a8d0dcf )
  1321.     ROM_LOAD( "7c",   0x38000, 0x2000, 0x9df7172d )
  1322.     ROM_LOAD( "8c",   0x3a000, 0x2000, 0x63b2e4f3 )
  1323.     ROM_LOAD( "10c",  0x3c000, 0x2000, 0x3b430adc )
  1324.     ROM_LOAD( "11c",  0x3e000, 0x2000, 0x04301032 )
  1325.     ROM_LOAD( "1b",   0x40000, 0x2000, 0x70e25cae )
  1326.     ROM_LOAD( "3b",   0x42000, 0x2000, 0xd09d167e )
  1327.     ROM_LOAD( "4b",   0x44000, 0x2000, 0xf46aba0d )
  1328.     ROM_LOAD( "6b",   0x46000, 0x2000, 0x8eb46f40 )
  1329.     ROM_LOAD( "7b",   0x48000, 0x2000, 0x3be9b1bd )
  1330.     ROM_LOAD( "8b",   0x4a000, 0x2000, 0xae977f4c )
  1331.     ROM_LOAD( "10b",  0x4c000, 0x2000, 0x502da003 )
  1332.  
  1333.     ROM_REGION( 0x10000, REGION_CPU2 )
  1334.     ROM_LOAD( "1h",  0x0e000, 0x2000, 0x8f3dd350 )
  1335.  
  1336.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1337.     ROM_LOAD( "2k",          0x00000, 0x2000, 0x1c9df8b5 )
  1338.     ROM_LOAD( "2l",          0x02000, 0x2000, 0x6b733306 )
  1339.     ROM_LOAD( "2m",          0x04000, 0x2000, 0xdc074733 )
  1340.     ROM_LOAD( "2n",          0x06000, 0x2000, 0x7985867f )
  1341.     ROM_LOAD( "2p",           0x08000, 0x2000, 0x88684dcf )
  1342.     ROM_LOAD( "2r",          0x0a000, 0x2000, 0x5857321e )
  1343.     ROM_LOAD( "2s",          0x0c000, 0x2000, 0x371e5235 )
  1344.     ROM_LOAD( "2t",           0x0e000, 0x2000, 0x7ae65f05 )
  1345.     ROM_LOAD( "1k",        0x10000, 0x2000, 0xf748ea87 )
  1346.     ROM_LOAD( "xba-1.2s", 0x16000, 0x2000, 0x14dd8993 )    /* from Crossbow */
  1347.     ROM_LOAD( "xba-1.1n", 0x18000, 0x2000, 0x2e855698 )    /* from Crossbow */
  1348.     ROM_LOAD( "xba-1.1p", 0x1a000, 0x2000, 0x788bfac6 )    /* from Crossbow */
  1349.     ROM_LOAD( "xba-1.2l", 0x1c000, 0x2000, 0x2c24cb35 )    /* from Crossbow */
  1350.     ROM_LOAD( "xba-1.1t", 0x1e000, 0x2000, 0x5f41c282 )    /* from Crossbow */
  1351. ROM_END
  1352.  
  1353.  
  1354. ROM_START( cracksht )
  1355.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1356.     ROM_LOAD( "csl2.1a",   0x08000, 0x2000, 0x16fd0171 )
  1357.     ROM_LOAD( "csl2.3a",   0x0a000, 0x2000, 0x906f3209 )
  1358.     ROM_LOAD( "csl2.4a",   0x0c000, 0x2000, 0x9996d2bf )
  1359.     ROM_LOAD( "csl2.6a",   0x0e000, 0x2000, 0xc8d6e945 )
  1360.     ROM_LOAD( "csl2.11d",  0x2e000, 0x2000, 0xb1173dd3 )
  1361.     ROM_LOAD( "csl2.1c",   0x30000, 0x2000, 0xe44975a7 )
  1362.     ROM_LOAD( "csl2.3c",   0x32000, 0x2000, 0xa3ab11e9 )
  1363.     ROM_LOAD( "csl2.4c",   0x34000, 0x2000, 0x89266302 )
  1364.     ROM_LOAD( "csl2.6c",   0x36000, 0x2000, 0xbb0f8d32 )
  1365.     ROM_LOAD( "csl2.7c",   0x38000, 0x2000, 0xe203ed0b )
  1366.     ROM_LOAD( "csl2.8c",   0x3a000, 0x2000, 0x3e028a62 )
  1367.     ROM_LOAD( "csl2.10c",  0x3c000, 0x2000, 0xc5494f9f )
  1368.     ROM_LOAD( "csl2.11c",  0x3e000, 0x2000, 0x0159bdcb )
  1369.     ROM_LOAD( "csl2.1b",   0x40000, 0x2000, 0x8adf33fc )
  1370.     ROM_LOAD( "csl2.3b",   0x42000, 0x2000, 0x7561be69 )
  1371.     ROM_LOAD( "csl2.4b",   0x44000, 0x2000, 0x848e3aff )
  1372.     ROM_LOAD( "csl2.6b",   0x46000, 0x2000, 0xd0fd87df )
  1373.     ROM_LOAD( "csl2.7b",   0x48000, 0x2000, 0x7e0a6a31 )
  1374.     ROM_LOAD( "csl2.8b",   0x4a000, 0x2000, 0xaf1c8cb8 )
  1375.     ROM_LOAD( "csl2.10b",  0x4c000, 0x2000, 0x8a0d6ad0 )
  1376.  
  1377.     ROM_REGION( 0x10000, REGION_CPU2 )
  1378.     ROM_LOAD( "csa3.1h",   0x0e000, 0x2000, 0x5ba8b4ac )
  1379.  
  1380.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1381.     ROM_LOAD( "csa3.2k",   0x00000, 0x2000, 0x067a4f71 )
  1382.     ROM_LOAD( "csa3.2l",   0x02000, 0x2000, 0x5716c59e )
  1383.     ROM_LOAD( "csa3.2m",   0x04000, 0x2000, 0xb3ff659b )
  1384.     ROM_LOAD( "csa3.2n",   0x06000, 0x2000, 0xa8968342 )
  1385.     ROM_LOAD( "csa3.2p",   0x08000, 0x2000, 0x5db225b8 )
  1386.     ROM_LOAD( "csa3.2r",   0x0a000, 0x2000, 0xfda2669d )
  1387.     ROM_LOAD( "csa3.2s",   0x0c000, 0x2000, 0xe8d2413f )
  1388.     ROM_LOAD( "csa3.2t",   0x0e000, 0x2000, 0x841a1855 )
  1389.     ROM_LOAD( "csa3.1k",   0x10000, 0x2000, 0x27dda69b )
  1390.     ROM_LOAD( "csa3.1l",   0x12000, 0x2000, 0x86eea479 )
  1391.     ROM_LOAD( "csa3.1m",   0x14000, 0x2000, 0x2c24cb35 )
  1392.     ROM_LOAD( "csa3.1n",   0x16000, 0x2000, 0xf3a4f2be )
  1393.     ROM_LOAD( "csa3.1p",   0x18000, 0x2000, 0x14dd8993 )
  1394.     ROM_LOAD( "csa3.1r",   0x1a000, 0x2000, 0xdfa783e4 )
  1395.     ROM_LOAD( "csa3.1s",   0x1c000, 0x2000, 0x18d097ac )
  1396.     ROM_LOAD( "csa3.1t",   0x1e000, 0x2000, 0x5f41c282 )
  1397. ROM_END
  1398.  
  1399.  
  1400. ROM_START( claypign )
  1401.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1402.     ROM_LOAD( "claypige.1a",   0x08000, 0x2000, 0x446d7004 )
  1403.     ROM_LOAD( "claypige.3a",   0x0a000, 0x2000, 0xdf39701b )
  1404.     ROM_LOAD( "claypige.4a",   0x0c000, 0x2000, 0xf205afb8 )
  1405.     ROM_LOAD( "claypige.6a",   0x0e000, 0x2000, 0x97c36c6c )
  1406.     ROM_LOAD( "claypige.10c",  0x3c000, 0x2000, 0x3d2957cd )
  1407.     ROM_LOAD( "claypige.11c",  0x3e000, 0x2000, 0xe162a3af )
  1408.     ROM_LOAD( "claypige.1b",   0x40000, 0x2000, 0x90f1e534 )
  1409.     ROM_LOAD( "claypige.3b",   0x42000, 0x2000, 0x150c5993 )
  1410.     ROM_LOAD( "claypige.4b",   0x44000, 0x2000, 0xdabb99fb )
  1411.     ROM_LOAD( "claypige.6b",   0x46000, 0x2000, 0xc3b86d26 )
  1412.     ROM_LOAD( "claypige.7b",   0x48000, 0x2000, 0x6140b026 )
  1413.     ROM_LOAD( "claypige.8b",   0x4a000, 0x2000, 0xd0f9d170 )
  1414.  
  1415.     ROM_REGION( 0x10000, REGION_CPU2 )
  1416.     ROM_LOAD( "claypige.h1",   0x0e000, 0x2000, 0x9eedc68d )
  1417.  
  1418.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1419.     ROM_LOAD( "claypige.k2",   0x00000, 0x2000, 0x0dd93c6c )
  1420.     ROM_LOAD( "claypige.l2",   0x02000, 0x2000, 0xe1d67c42 )
  1421.     ROM_LOAD( "claypige.m2",   0x04000, 0x2000, 0xb56d8bd5 )
  1422.     ROM_LOAD( "claypige.n2",   0x06000, 0x2000, 0x9e381cb5 )
  1423.     ROM_LOAD( "xba-1.2l",       0x08000, 0x2000, 0x2c24cb35 )        /* from Crossbow */
  1424.     ROM_LOAD( "xba-1.2k",        0x0a000, 0x2000, 0xb6e57685 )        /* from Crossbow */
  1425.     ROM_LOAD( "xba-1.1m",          0x0c000, 0x2000, 0x18d097ac )        /* from Crossbow */
  1426.     ROM_LOAD( "xba-1.1t",       0x0e000, 0x2000, 0x5f41c282 )        /* from Crossbow */
  1427.     ROM_LOAD( "claypige.k1",   0x10000, 0x2000, 0x07f12d18 )
  1428.     ROM_LOAD( "claypige.l1",   0x12000, 0x2000, 0xf448eb4f )
  1429.     ROM_LOAD( "claypige.m1",   0x14000, 0x2000, 0x36865f5b )
  1430. ROM_END
  1431.  
  1432.  
  1433. ROM_START( chiller )
  1434.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1435.     ROM_LOAD( "chl3.1a",   0x08000, 0x2000, 0x996ad02e )
  1436.     ROM_LOAD( "chl3.3a",   0x0a000, 0x2000, 0x17e6f904 )
  1437.     ROM_LOAD( "chl3.4a",   0x0c000, 0x2000, 0xf30d6e32 )
  1438.     ROM_LOAD( "chl3.6a",   0x0e000, 0x2000, 0xf64fa8fe )
  1439.     ROM_LOAD( "chl3.1d",   0x20000, 0x2000, 0xce4aa4b0 )
  1440.     ROM_LOAD( "chl3.3d",   0x22000, 0x2000, 0xa234952e )
  1441.     ROM_LOAD( "chl3.4d",   0x24000, 0x2000, 0x645dbae9 )
  1442.     ROM_LOAD( "chl3.6d",   0x26000, 0x2000, 0x440a5cd7 )
  1443.     ROM_LOAD( "chl3.7d",   0x28000, 0x2000, 0x062a541f )
  1444.     ROM_LOAD( "chl3.8d",   0x2a000, 0x2000, 0x31ff8f48 )
  1445.     ROM_LOAD( "chl3.10d",  0x2c000, 0x2000, 0x5bceb965 )
  1446.     ROM_LOAD( "chl3.11d",  0x2e000, 0x2000, 0xe16b5db3 )
  1447.     ROM_LOAD( "chl3.1c",   0x30000, 0x2000, 0xebfd29e8 )
  1448.     ROM_LOAD( "chl3.3c",   0x32000, 0x2000, 0xa04261e5 )
  1449.     ROM_LOAD( "chl3.4c",   0x34000, 0x2000, 0x6fcbb15b )
  1450.     ROM_LOAD( "chl3.6c",   0x36000, 0x2000, 0xbd0e0689 )
  1451.     ROM_LOAD( "chl3.7c",   0x38000, 0x2000, 0x2715571e )
  1452.     ROM_LOAD( "chl3.8c",   0x3a000, 0x2000, 0x364d9450 )
  1453.     ROM_LOAD( "chl3.10c",  0x3c000, 0x2000, 0x13180106 )
  1454.     ROM_LOAD( "chl3.11c",  0x3e000, 0x2000, 0x4a7ffe6f )
  1455.     ROM_LOAD( "chl3.1b",   0x40000, 0x2000, 0x20c19bb6 )
  1456.     ROM_LOAD( "chl3.3b",   0x42000, 0x2000, 0xe1f07ace )
  1457.     ROM_LOAD( "chl3.4b",   0x44000, 0x2000, 0x140d95db )
  1458.     ROM_LOAD( "chl3.6b",   0x46000, 0x2000, 0xfaaf7cc8 )
  1459.     ROM_LOAD( "chl3.7b",   0x48000, 0x2000, 0x5512b7e6 )
  1460.     ROM_LOAD( "chl3.8b",   0x4a000, 0x2000, 0x6172b12f )
  1461.     ROM_LOAD( "chl3.10b",  0x4c000, 0x2000, 0x5d15342a )
  1462.  
  1463.     ROM_REGION( 0x10000, REGION_CPU2 )
  1464.     ROM_LOAD( "cha3.1h",   0x0f000, 0x1000, 0xb195cbba )
  1465.  
  1466.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1467.     ROM_LOAD( "cha3.2k",   0x00000, 0x2000, 0x814a1c6e )
  1468.     ROM_LOAD( "cha3.2l",   0x02000, 0x2000, 0xb326007f )
  1469.     ROM_LOAD( "cha3.2m",   0x04000, 0x2000, 0x11075e8c )
  1470.     ROM_LOAD( "cha3.2n",   0x06000, 0x2000, 0x8c3f6184 )
  1471.     ROM_LOAD( "cha3.2p",   0x08000, 0x2000, 0x3a8b4d0f )
  1472.     ROM_LOAD( "cha3.2r",   0x0a000, 0x2000, 0xfc6c4e00 )
  1473.     ROM_LOAD( "cha3.2s",   0x0c000, 0x2000, 0x2440d5f3 )
  1474.     ROM_LOAD( "cha3.2t",   0x0e000, 0x2000, 0x9b2ce556 )
  1475.     ROM_LOAD( "cha3.1k",   0x10000, 0x2000, 0x27f86fab )
  1476.     ROM_LOAD( "cha3.1l",   0x12000, 0x2000, 0x581dfde7 )
  1477.     ROM_LOAD( "cha3.1m",   0x14000, 0x2000, 0x36d47696 )
  1478.     ROM_LOAD( "cha3.1n",   0x16000, 0x2000, 0xce47bffe )
  1479.     ROM_LOAD( "cha3.1p",   0x18000, 0x2000, 0x788bfac6 )
  1480.     ROM_LOAD( "cha3.1r",   0x1a000, 0x2000, 0xb8ec43b3 )
  1481.     ROM_LOAD( "cha3.1s",   0x1c000, 0x2000, 0x5f41c282 )
  1482.     ROM_LOAD( "cha3.1t",   0x1e000, 0x2000, 0x3a3a48af )
  1483. ROM_END
  1484.  
  1485.  
  1486. ROM_START( topsecex )
  1487.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1488.     ROM_LOAD( "tsl1.a1",   0x08000, 0x2000, 0x30ff2142 )
  1489.     ROM_LOAD( "tsl1.a3",   0x0a000, 0x2000, 0x9295e5b7 )
  1490.     ROM_LOAD( "tsl1.a4",   0x0c000, 0x2000, 0x402abca4 )
  1491.     ROM_LOAD( "tsl1.a6",   0x0e000, 0x2000, 0x66eac7d8 )
  1492.     ROM_LOAD( "tsl1.e3",   0x12000, 0x2000, 0xf5b291fc )
  1493.     ROM_LOAD( "tsl1.e4",   0x14000, 0x2000, 0xb6c659ae )
  1494.     ROM_LOAD( "tsl1.e6",   0x16000, 0x2000, 0xcf457523 )
  1495.     ROM_LOAD( "tsl1.e7",   0x18000, 0x2000, 0x5a29304c )
  1496.     ROM_LOAD( "tsl1.e8",   0x1a000, 0x2000, 0x0750893b )
  1497.     ROM_LOAD( "tsl1.e10",  0x1c000, 0x2000, 0xfb87a723 )
  1498.     ROM_LOAD( "tsl1.e11",  0x1e000, 0x2000, 0xecf78fac )
  1499.     ROM_LOAD( "tsl1.d1",   0x20000, 0x2000, 0x3a316cbe )
  1500.     ROM_LOAD( "tsl1.d3",   0x22000, 0x2000, 0x58408a5f )
  1501.     ROM_LOAD( "tsl1.d4",   0x24000, 0x2000, 0xc3c85c13 )
  1502.     ROM_LOAD( "tsl1.d6",   0x26000, 0x2000, 0xf26a2864 )
  1503.     ROM_LOAD( "tsl1.d7",   0x28000, 0x2000, 0x53195dc6 )
  1504.     ROM_LOAD( "tsl1.d8",   0x2a000, 0x2000, 0x4fcfb3c8 )
  1505.     ROM_LOAD( "tsl1.d10",  0x2c000, 0x2000, 0x6e20af8d )
  1506.     ROM_LOAD( "tsl1.d11",  0x2e000, 0x2000, 0x58c670e7 )
  1507.     ROM_LOAD( "tsl1.c1",   0x30000, 0x2000, 0x630521f8 )
  1508.     ROM_LOAD( "tsl1.c3",   0x32000, 0x2000, 0xd0d7d908 )
  1509.     ROM_LOAD( "tsl1.c4",   0x34000, 0x2000, 0xdc2193c4 )
  1510.     ROM_LOAD( "tsl1.c6",   0x36000, 0x2000, 0xde417d5f )
  1511.     ROM_LOAD( "tsl1.c7",   0x38000, 0x2000, 0xd75708c3 )
  1512.     ROM_LOAD( "tsl1.c8",   0x3a000, 0x2000, 0x69f639fd )
  1513.     ROM_LOAD( "tsl1.c10",  0x3c000, 0x2000, 0x5977e312 )
  1514.     ROM_LOAD( "tsl1.c11",  0x3e000, 0x2000, 0x07a6a534 )
  1515.     ROM_LOAD( "tsl1.b1",   0x40000, 0x2000, 0x771ec128 )
  1516.     ROM_LOAD( "tsl1.b3",   0x42000, 0x2000, 0xe57af802 )
  1517.     ROM_LOAD( "tsl1.b4",   0x44000, 0x2000, 0x7d63fe09 )
  1518.     ROM_LOAD( "tsl1.b6",   0x46000, 0x2000, 0xe6c85d95 )
  1519.     ROM_LOAD( "tsl1.b7",   0x48000, 0x2000, 0xbabb7e24 )
  1520.     ROM_LOAD( "tsl1.b8",   0x4a000, 0x2000, 0xcc770802 )
  1521.     ROM_LOAD( "tsl1.b10",  0x4c000, 0x2000, 0x079d0a1d )
  1522.  
  1523.     ROM_REGION( 0x10000, REGION_CPU2 )
  1524.     ROM_LOAD( "tsa1.1h",   0x0e000, 0x2000, 0x35a1dd40 )
  1525.  
  1526.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1527.     ROM_LOAD( "tsa1.2k",   0x00000, 0x2000, 0xc0b7c8f9 )
  1528.     ROM_LOAD( "tsa1.2l",   0x02000, 0x2000, 0xd46f2f23 )
  1529.     ROM_LOAD( "tsa1.2m",   0x04000, 0x2000, 0x04722ee4 )
  1530.     ROM_LOAD( "tsa1.2n",   0x06000, 0x2000, 0x266348a2 )
  1531.     ROM_LOAD( "tsa1.2p",   0x08000, 0x2000, 0x33491a21 )
  1532.     ROM_LOAD( "tsa1.2r",   0x0a000, 0x2000, 0x669fb97a )
  1533.     ROM_LOAD( "tsa1.2s",   0x0c000, 0x2000, 0xa9167bc2 )
  1534.     ROM_LOAD( "tsa1.2t",   0x0e000, 0x2000, 0x26bcd7ff )
  1535.     ROM_LOAD( "tsa1.1k",   0x10000, 0x2000, 0x60e9035d )
  1536.     ROM_LOAD( "tsa1.1l",   0x12000, 0x2000, 0x7de3bfa7 )
  1537.     ROM_LOAD( "tsa1.1m",   0x14000, 0x2000, 0x77a86aef )
  1538.     ROM_LOAD( "tsa1.1n",   0x16000, 0x2000, 0x4ffc26a7 )
  1539.     ROM_LOAD( "tsa1.1p",   0x18000, 0x2000, 0xd0c699aa )
  1540.     ROM_LOAD( "tsa1.1r",   0x1a000, 0x2000, 0x753f0a5f )
  1541.     ROM_LOAD( "tsa1.1s",   0x1c000, 0x2000, 0x745f9340 )
  1542.     ROM_LOAD( "tsa1.1t",   0x1e000, 0x2000, 0x0e74b7a6 )
  1543. ROM_END
  1544.  
  1545.  
  1546. ROM_START( hitnmiss )
  1547.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1548.     ROM_LOAD( "hml3.a1",   0x08000, 0x2000, 0xd79ae18e )
  1549.     ROM_LOAD( "hml3.a3",   0x0a000, 0x2000, 0x61baf38b )
  1550.     ROM_LOAD( "hml3.a4",   0x0c000, 0x2000, 0x60ca260b )
  1551.     ROM_LOAD( "hml3.a6",   0x0e000, 0x2000, 0x073305d8 )
  1552.     ROM_LOAD( "hml3.d6",   0x26000, 0x2000, 0x79578952 )
  1553.     ROM_LOAD( "hml3.d7",   0x28000, 0x2000, 0x8043b78e )
  1554.     ROM_LOAD( "hml3.d8",   0x2a000, 0x2000, 0xa6494e2e )
  1555.     ROM_LOAD( "hml3.d10",  0x2c000, 0x2000, 0x0810cc84 )
  1556.     ROM_LOAD( "hml3.d11",  0x2e000, 0x2000, 0x9f5c3799 )
  1557.     ROM_LOAD( "hml3.c1",   0x30000, 0x2000, 0x6606d5a8 )
  1558.     ROM_LOAD( "hml3.c3",   0x32000, 0x2000, 0xf6b12e48 )
  1559.     ROM_LOAD( "hml3.c4",   0x34000, 0x2000, 0xe5031d44 )
  1560.     ROM_LOAD( "hml3.c6",   0x36000, 0x2000, 0x1b0f2f28 )
  1561.     ROM_LOAD( "hml3.c7",   0x38000, 0x2000, 0x44920233 )
  1562.     ROM_LOAD( "hml3.c8",   0x3a000, 0x2000, 0x7db26fad )
  1563.     ROM_LOAD( "hml3.c10",  0x3c000, 0x2000, 0xb8f99481 )
  1564.     ROM_LOAD( "hml3.c11",  0x3e000, 0x2000, 0xc2a0d170 )
  1565.     ROM_LOAD( "hml3.b1",   0x40000, 0x2000, 0x945cb27c )
  1566.     ROM_LOAD( "hml3.b3",   0x42000, 0x2000, 0x3f022689 )
  1567.     ROM_LOAD( "hml3.b4",   0x44000, 0x2000, 0xd63fd250 )
  1568.     ROM_LOAD( "hml3.b6",   0x46000, 0x2000, 0xafc89eed )
  1569.     ROM_LOAD( "hml3.b7",   0x48000, 0x2000, 0xf3a12a58 )
  1570.     ROM_LOAD( "hml3.b8",   0x4a000, 0x2000, 0xe0a5a6aa )
  1571.     ROM_LOAD( "hml3.b10",  0x4c000, 0x2000, 0xde65dfdc )
  1572.  
  1573.     ROM_REGION( 0x10000, REGION_CPU2 )
  1574.     ROM_LOAD( "hma3.1h",  0x0e000, 0x2000, 0xf718da36 )
  1575.  
  1576.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1577.     ROM_LOAD( "hm2.2k",   0x00000, 0x2000, 0xd3583b62 )
  1578.     ROM_LOAD( "hm2.2l",   0x02000, 0x2000, 0xc059d51e )
  1579.     ROM_LOAD( "hma.2m",   0x04000, 0x2000, 0x09bb8495 )
  1580.     ROM_LOAD( "hma.2n",   0x06000, 0x2000, 0xe3d290df )
  1581.     ROM_LOAD( "hma.2p",   0x08000, 0x2000, 0xf93d1ac0 )
  1582.     ROM_LOAD( "hma.2r",   0x0a000, 0x2000, 0x0f3a090e )
  1583.     ROM_LOAD( "hma.2s",   0x0c000, 0x2000, 0xc5d35f84 )
  1584.     ROM_LOAD( "hma.2t",   0x0e000, 0x2000, 0x9aa71457 )
  1585.     ROM_LOAD( "xba.1n",   0x16000, 0x2000, 0x2e855698 )
  1586.     ROM_LOAD( "hma.1p",   0x18000, 0x2000, 0x021d89dd )
  1587.     ROM_LOAD( "hma.1r",   0x1a000, 0x2000, 0xe8bb33bc )
  1588.     ROM_LOAD( "hma.1s",   0x1c000, 0x2000, 0x65f1aa6e )
  1589.     ROM_LOAD( "hma.1t",   0x1e000, 0x2000, 0xeb35dfcc )
  1590. ROM_END
  1591.  
  1592.  
  1593. ROM_START( hitnmis2 )
  1594.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1595.     ROM_LOAD( "hml2.a1",   0x08000, 0x2000, 0x322f7e83 )
  1596.     ROM_LOAD( "hml2.a3",   0x0a000, 0x2000, 0x0e12a721 )
  1597.     ROM_LOAD( "hml2.a4",   0x0c000, 0x2000, 0x6cec8ad2 )
  1598.     ROM_LOAD( "hml2.a6",   0x0e000, 0x2000, 0x008803ec )
  1599.     ROM_LOAD( "hml2.d4",   0x24000, 0x2000, 0x62790789 )
  1600.     ROM_LOAD( "hml2.d6",   0x26000, 0x2000, 0x02d2d07e )
  1601.     ROM_LOAD( "hml2.d7",   0x28000, 0x2000, 0x0f795f7a )
  1602.     ROM_LOAD( "hml2.d8",   0x2a000, 0x2000, 0xfe40c51d )
  1603.     ROM_LOAD( "hml2.d10",  0x2c000, 0x2000, 0x9362c90c )
  1604.     ROM_LOAD( "hml2.d11",  0x2e000, 0x2000, 0x0f77322f )
  1605.     ROM_LOAD( "hml2.c1",   0x30000, 0x2000, 0x8e5803ff )
  1606.     ROM_LOAD( "hml2.c3",   0x32000, 0x2000, 0xa7474441 )
  1607.     ROM_LOAD( "hml2.c4",   0x34000, 0x2000, 0xc74b9610 )
  1608.     ROM_LOAD( "hml2.c6",   0x36000, 0x2000, 0xaca63300 )
  1609.     ROM_LOAD( "hml2.c7",   0x38000, 0x2000, 0x1990305e )
  1610.     ROM_LOAD( "hml2.c8",   0x3a000, 0x2000, 0xbf08cf05 )
  1611.     ROM_LOAD( "hml2.c10",  0x3c000, 0x2000, 0x971323ca )
  1612.     ROM_LOAD( "hml2.c11",  0x3e000, 0x2000, 0xdd172feb )
  1613.     ROM_LOAD( "hml2.b1",   0x40000, 0x2000, 0xaf1fce57 )
  1614.     ROM_LOAD( "hml2.b3",   0x42000, 0x2000, 0x0d16ef47 )
  1615.     ROM_LOAD( "hml2.b4",   0x44000, 0x2000, 0xd5a8ff68 )
  1616.     ROM_LOAD( "hml2.b6",   0x46000, 0x2000, 0x13f439b1 )
  1617.     ROM_LOAD( "hml2.b7",   0x48000, 0x2000, 0x9088c16d )
  1618.     ROM_LOAD( "hml2.b8",   0x4a000, 0x2000, 0x9c2db94a )
  1619.     ROM_LOAD( "hml2.b10",  0x4c000, 0x2000, 0xf01bd7d4 )
  1620.  
  1621.     ROM_REGION( 0x10000, REGION_CPU2 )
  1622.     ROM_LOAD( "hma2.1h",  0x0e000, 0x2000, 0x9be48f45 )
  1623.  
  1624.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1625.     ROM_LOAD( "hm2.2k",   0x00000, 0x2000, 0xd3583b62 )
  1626.     ROM_LOAD( "hm2.2l",   0x02000, 0x2000, 0xc059d51e )
  1627.     ROM_LOAD( "hma.2m",   0x04000, 0x2000, 0x09bb8495 )
  1628.     ROM_LOAD( "hma.2n",   0x06000, 0x2000, 0xe3d290df )
  1629.     ROM_LOAD( "hma.2p",   0x08000, 0x2000, 0xf93d1ac0 )
  1630.     ROM_LOAD( "hma.2r",   0x0a000, 0x2000, 0x0f3a090e )
  1631.     ROM_LOAD( "hma.2s",   0x0c000, 0x2000, 0xc5d35f84 )
  1632.     ROM_LOAD( "hma.2t",   0x0e000, 0x2000, 0x9aa71457 )
  1633.     ROM_LOAD( "xba.1n",   0x16000, 0x2000, 0x2e855698 )
  1634.     ROM_LOAD( "hma.1p",   0x18000, 0x2000, 0x021d89dd )
  1635.     ROM_LOAD( "hma.1r",   0x1a000, 0x2000, 0xe8bb33bc )
  1636.     ROM_LOAD( "hma.1s",   0x1c000, 0x2000, 0x65f1aa6e )
  1637.     ROM_LOAD( "hma.1t",   0x1e000, 0x2000, 0xeb35dfcc )
  1638. ROM_END
  1639.  
  1640.  
  1641. ROM_START( whodunit )
  1642.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1643.     ROM_LOAD( "wdl8.1a",   0x08000, 0x2000, 0x50658904 )
  1644.     ROM_LOAD( "wdl8.3a",   0x0a000, 0x2000, 0x5d1530f8 )
  1645.     ROM_LOAD( "wdl8.4a",   0x0c000, 0x2000, 0x0323d6b8 )
  1646.     ROM_LOAD( "wdl8.6a",   0x0e000, 0x2000, 0x771b3fb1 )
  1647.     ROM_LOAD( "wdl8.4e",   0x14000, 0x2000, 0x33e44369 )
  1648.     ROM_LOAD( "wdl8.6e",   0x16000, 0x2000, 0x64b1d850 )
  1649.     ROM_LOAD( "wdl8.7e",   0x18000, 0x2000, 0xaa54cf90 )
  1650.     ROM_LOAD( "wdl8.8e",   0x1a000, 0x2000, 0xcbd61200 )
  1651.     ROM_LOAD( "wdl8.10e",  0x1c000, 0x2000, 0xf24adde5 )
  1652.     ROM_LOAD( "wdl8.11e",  0x1e000, 0x2000, 0xad6fe69e )
  1653.     ROM_LOAD( "wdl6.1d",   0x20000, 0x2000, 0x3572fb71 )
  1654.     ROM_LOAD( "wdl6.3d",   0x22000, 0x2000, 0x158074f4 )
  1655.     ROM_LOAD( "wdl8.4d",   0x24000, 0x2000, 0x601d8bd0 )
  1656.     ROM_LOAD( "wdl8.6d",   0x26000, 0x2000, 0xb72e8f63 )
  1657.     ROM_LOAD( "wdl6.7d",   0x28000, 0x2000, 0xe3f55a4b )
  1658.     ROM_LOAD( "wdl6.8d",   0x2a000, 0x2000, 0x932689c8 )
  1659.     ROM_LOAD( "wdl6.10d",  0x2c000, 0x2000, 0x0c4348f2 )
  1660.     ROM_LOAD( "wdl8.11d",  0x2e000, 0x2000, 0x92391ffe )
  1661.     ROM_LOAD( "wdl8.1c",   0x30000, 0x2000, 0x21c62c90 )
  1662.     ROM_LOAD( "wdl8.3c",   0x32000, 0x2000, 0x5a8123be )
  1663.     ROM_LOAD( "wdl6.4c",   0x34000, 0x2000, 0x7b58dfac )
  1664.     ROM_LOAD( "wdl6.6c",   0x36000, 0x2000, 0x9be0b9a9 )
  1665.     ROM_LOAD( "wdl6.7c",   0x38000, 0x2000, 0x3cb3faae )
  1666.     ROM_LOAD( "wdl6.8c",   0x3a000, 0x2000, 0x51e95d91 )
  1667.     ROM_LOAD( "wdl6.10c",  0x3c000, 0x2000, 0xeab12084 )
  1668.     ROM_LOAD( "wdl6.11c",  0x3e000, 0x2000, 0xfe2c532f )
  1669.     ROM_LOAD( "wdl6.1b",   0x40000, 0x2000, 0xcdaa5ca0 )
  1670.     ROM_LOAD( "wdl6.3b",   0x42000, 0x2000, 0x9bbc8161 )
  1671.     ROM_LOAD( "wdl8.4b",   0x44000, 0x2000, 0xeb7dc583 )
  1672.     ROM_LOAD( "wdl8.6b",   0x46000, 0x2000, 0x91c049a5 )
  1673.     ROM_LOAD( "wdl6.7b",   0x48000, 0x2000, 0xfe0a2d00 )
  1674.     ROM_LOAD( "wdl8.8b",   0x4a000, 0x2000, 0x33792758 )
  1675.     ROM_LOAD( "wdl6.10b",  0x4c000, 0x2000, 0x2f48cfdb )
  1676.  
  1677.     ROM_REGION( 0x10000, REGION_CPU2 )
  1678.     ROM_LOAD( "wda8.h1",  0x0e000, 0x2000, 0x0090e5a7 )
  1679.  
  1680.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1681.     ROM_LOAD( "wda6.k2",   0x00000, 0x2000, 0xd4951375 )
  1682.     ROM_LOAD( "wda6.l2",   0x02000, 0x2000, 0xbe8dcf07 )
  1683.     ROM_LOAD( "wda6.m2",   0x04000, 0x2000, 0xfb389e2d )
  1684.     ROM_LOAD( "wda6.n2",   0x06000, 0x2000, 0x3849bc78 )
  1685.     ROM_LOAD( "wda6.p2",   0x08000, 0x2000, 0xd0dcea80 )
  1686.     ROM_LOAD( "wda6.r2",   0x0a000, 0x2000, 0x748b0930 )
  1687.     ROM_LOAD( "wda6.s2",   0x0c000, 0x2000, 0x23d5c5a9 )
  1688.     ROM_LOAD( "wda6.t2",   0x0e000, 0x2000, 0xa807536d )
  1689.     ROM_LOAD( "wda8.l1",   0x12000, 0x2000, 0x27b856bd )
  1690.     ROM_LOAD( "wda8.m1",   0x14000, 0x2000, 0x8e15c601 )
  1691.     ROM_LOAD( "xba1.1n",   0x16000, 0x2000, 0x2e855698 )
  1692.     ROM_LOAD( "wda6.p1",   0x18000, 0x2000, 0x3ffaaa22 )
  1693.     ROM_LOAD( "wda6.r1",   0x1a000, 0x2000, 0x0579a3b8 )
  1694.     ROM_LOAD( "wda6.s1",   0x1c000, 0x2000, 0xf55c3c6e )
  1695.     ROM_LOAD( "wda6.t1",   0x1e000, 0x2000, 0x38363b52 )
  1696. ROM_END
  1697.  
  1698.  
  1699. ROM_START( showdown )
  1700.     ROM_REGION( 0x50000, REGION_CPU1 )     /* 64k for code for the first CPU, plus lots of banked ROMs */
  1701.     ROM_LOAD( "showda1.bin",   0x08000, 0x2000, 0xe4031507 )
  1702.     ROM_LOAD( "showd3a.bin",   0x0a000, 0x2000, 0xe7de171e )
  1703.     ROM_LOAD( "showd4a.bin",   0x0c000, 0x2000, 0x5c8683c9 )
  1704.     ROM_LOAD( "showd6a.bin",   0x0e000, 0x2000, 0x4a408379 )
  1705.     ROM_LOAD( "showd11e.bin",  0x1e000, 0x2000, 0x1c6b34e5 )
  1706.     ROM_LOAD( "showd1d.bin",   0x20000, 0x2000, 0xdb4c8cf6 )
  1707.     ROM_LOAD( "showd3d.bin",   0x22000, 0x2000, 0x24242867 )
  1708.     ROM_LOAD( "showd4d.bin",   0x24000, 0x2000, 0x36f247e9 )
  1709.     ROM_LOAD( "showd6d.bin",   0x26000, 0x2000, 0xc9b14d8d )
  1710.     ROM_LOAD( "showd7d.bin",   0x28000, 0x2000, 0xfd054cd2 )
  1711.     ROM_LOAD( "showd8d.bin",   0x2a000, 0x2000, 0x8bf32822 )
  1712.     ROM_LOAD( "showd10d.bin",  0x2c000, 0x2000, 0xa2051da2 )
  1713.     ROM_LOAD( "showd11d.bin",  0x2e000, 0x2000, 0x0748f345 )
  1714.     ROM_LOAD( "showd1c.bin",   0x30000, 0x2000, 0xc016cf73 )
  1715.     ROM_LOAD( "showd3c.bin",   0x32000, 0x2000, 0x652503ee )
  1716.     ROM_LOAD( "showd4c.bin",   0x34000, 0x2000, 0xb4dab193 )
  1717.     ROM_LOAD( "showd6c.bin",   0x36000, 0x2000, 0xa1e6a2b3 )
  1718.     ROM_LOAD( "showd7c.bin",   0x38000, 0x2000, 0xbc1bea93 )
  1719.     ROM_LOAD( "showd8c.bin",   0x3a000, 0x2000, 0x337dd7fa )
  1720.     ROM_LOAD( "showd10c.bin",  0x3c000, 0x2000, 0x3ad32d71 )
  1721.     ROM_LOAD( "showd11c.bin",  0x3e000, 0x2000, 0x5fe91932 )
  1722.     ROM_LOAD( "showd1b.bin",   0x40000, 0x2000, 0x54ff987e )
  1723.     ROM_LOAD( "showd3b.bin",   0x42000, 0x2000, 0xe302e915 )
  1724.     ROM_LOAD( "showd4b.bin",   0x44000, 0x2000, 0x1b981516 )
  1725.     ROM_LOAD( "showd6b.bin",   0x46000, 0x2000, 0x4ee00996 )
  1726.     ROM_LOAD( "showd7b.bin",   0x48000, 0x2000, 0x018b7c00 )
  1727.     ROM_LOAD( "showd8b.bin",   0x4a000, 0x2000, 0x024fe6ee )
  1728.     ROM_LOAD( "showd10b.bin",  0x4c000, 0x2000, 0x0b318dfe )
  1729.  
  1730.     ROM_REGION( 0x10000, REGION_CPU2 )
  1731.     ROM_LOAD( "showd1h.bin",  0x0e000, 0x2000, 0x6a10ff47 )
  1732.  
  1733.     ROM_REGION( 0x20000, REGION_SOUND1 )
  1734.     ROM_LOAD( "showd2k.bin",   0x00000, 0x2000, 0x67a86f7f )
  1735.     ROM_LOAD( "showd2l.bin",   0x02000, 0x2000, 0x0bb8874b )
  1736.     ROM_LOAD( "showd2m.bin",   0x04000, 0x2000, 0x8b77eac8 )
  1737.     ROM_LOAD( "showd2n.bin",   0x06000, 0x2000, 0x78e6eed6 )
  1738.     ROM_LOAD( "showd2p.bin",   0x08000, 0x2000, 0x03a13435 )
  1739.     ROM_LOAD( "showd2r.bin",   0x0a000, 0x2000, 0x1b6b7eac )
  1740.     ROM_LOAD( "showd2s.bin",   0x0c000, 0x2000, 0xb88aeb82 )
  1741.     ROM_LOAD( "showd2t.bin",   0x0e000, 0x2000, 0x5c801f4d )
  1742.     ROM_LOAD( "showd1k.bin",   0x10000, 0x2000, 0x4e1f4f15 )
  1743.     ROM_LOAD( "showd1l.bin",   0x12000, 0x2000, 0x6779a745 )
  1744.     ROM_LOAD( "showd1m.bin",   0x14000, 0x2000, 0x9cebd8ea )
  1745.     ROM_LOAD( "showd1n.bin",   0x16000, 0x2000, 0x689d8a3f )
  1746.     ROM_LOAD( "showd1p.bin",   0x18000, 0x2000, 0x862b350d )
  1747.     ROM_LOAD( "showd1r.bin",   0x1a000, 0x2000, 0x95b099ed )
  1748.     ROM_LOAD( "showd1s.bin",   0x1c000, 0x2000, 0x8f230881 )
  1749.     ROM_LOAD( "showd1t.bin",   0x1e000, 0x2000, 0x70e724c7 )
  1750. ROM_END
  1751.  
  1752.  
  1753.  
  1754. /*************************************
  1755.  *
  1756.  *    Game drivers
  1757.  *
  1758.  *************************************/
  1759.  
  1760. GAME( 1983, crossbow, 0,        exidy440, crossbow, crossbow, ROT0, "Exidy", "Crossbow (version 2.0)" )
  1761. GAME( 1984, cheyenne, 0,        exidy440, cheyenne, cheyenne, ROT0, "Exidy", "Cheyenne (version 1.0)" )
  1762. GAME( 1985, combat,   0,        exidy440, combat,   combat,   ROT0, "Exidy", "Combat (version 3.0)" )
  1763. GAME( 1985, cracksht, 0,        exidy440, cracksht, cracksht, ROT0, "Exidy", "Crackshot (version 2.0)" )
  1764. GAME( 1986, claypign, 0,        exidy440, claypign, claypign, ROT0, "Exidy", "Clay Pigeon (version 2.0)" )
  1765. GAME( 1986, chiller,  0,        exidy440, chiller,  chiller,  ROT0, "Exidy", "Chiller (version 3.0)" )
  1766. GAME( 1986, topsecex, 0,        exidy440, topsecex, topsecex, ROT0, "Exidy", "Top Secret (Exidy) (version 1.0)" )
  1767. GAME( 1987, hitnmiss, 0,        exidy440, hitnmiss, hitnmiss, ROT0, "Exidy", "Hit 'n Miss (version 3.0)" )
  1768. GAME( 1987, hitnmis2, hitnmiss, exidy440, hitnmiss, hitnmiss, ROT0, "Exidy", "Hit 'n Miss (version 2.0)" )
  1769. GAME( 1988, whodunit, 0,        exidy440, whodunit, whodunit, ROT0, "Exidy", "Who Dunit (version 8.0)" )
  1770. GAME( 1988, showdown, 0,        exidy440, showdown, showdown, ROT0, "Exidy", "Showdown (version 5.0)" )
  1771.